private void assertNewComponentGraphFails(Container container, ComponentGraph currentGraph, Class<? extends RuntimeException> exception) {
        try {
            getNewComponentGraph(container, currentGraph);
            fail("Expected exception");
        } catch (Exception e) {
            assertEquals(exception, e.getClass());
        }
    }
@author Tony Vaagenes
@author gjoranv
@author ollivir
container-core/src/test/java/com/yahoo/container/di/ContainerTest.java