use of org.apache.cayenne.di.spi.DefaultAdhocObjectFactory in project cayenne by apache.
the class ToolsModuleTest method testModuleContents.
@Test
public void testModuleContents() {
Logger log = mock(Logger.class);
Injector i = DIBootstrap.createInjector(new ToolsModule(log));
assertSame(log, i.getInstance(Logger.class));
assertTrue(i.getInstance(DataSourceFactory.class) instanceof DriverDataSourceFactory);
assertTrue(i.getInstance(AdhocObjectFactory.class) instanceof DefaultAdhocObjectFactory);
assertTrue(i.getInstance(DbAdapterFactory.class) instanceof DefaultDbAdapterFactory);
}
Aggregations