AtomikosXARecoverableResource extends JdbcTransactionalResource { @Override public boolean usesXAResource(final XAResource xaResource) { return resourceName.equals(((SingleXAResource) xaResource).getResourceName()); } AtomikosXARecoverableResource(final String serverName, final XADataSource xaDataSource); @Override boolean usesXAResource(final XAResource xaResource);  }
@Test public void assertUseXAResource() { AtomikosXARecoverableResource atomikosXARecoverableResource = new AtomikosXARecoverableResource("ds1", xaDataSource); assertTrue(atomikosXARecoverableResource.usesXAResource(singleXAResource)); }