ViburCpDatasourceAccessor implements DatasourceAccessor { @Override public boolean canMap(final Object resource) { return "org.vibur.dbcp.ViburDBCPDataSource".equals(resource.getClass().getName()) && resource instanceof ViburDBCPDataSource; }  @Override DataSourceInfo getInfo(final Object resource); @Override boolean reset(final Object resource); @Override boolean canMap(final Object resource);  }
@Test public void canMapTest() { Assertions.assertTrue(accessor.canMap(source)); }
@Test public void cannotMapTest() { Assertions.assertFalse(accessor.canMap(badSource)); }