DataSourceSwapper { public XADataSource swap(final DataSource dataSource) { XADataSource result = createXADataSource(); setProperties(result, getDatabaseAccessConfiguration(dataSource)); return result; }  XADataSource swap(final DataSource dataSource);  }
@Test public void assertSwapByDefaultProvider() { swapper = new DataSourceSwapper(xaDataSourceDefinition); assertResult(swapper.swap(createDBCPDataSource())); }
@Test public void assertSwapBySPIProvider() { swapper = new DataSourceSwapper(xaDataSourceDefinition); assertResult(swapper.swap(createHikariCPDataSource())); }