use of com.arjuna.ats.internal.jta.resources.arjunacore.SynchronizationImple in project narayana by jbosstm.
the class SynchronizationUnitTest method testValid.
@Test
public void testValid() {
SynchronizationImple sync = new SynchronizationImple(new Synchronization());
assertTrue(sync.get_uid().notEquals(Uid.nullUid()));
assertTrue(sync.beforeCompletion());
assertTrue(sync.afterCompletion(Status.STATUS_COMMITTED));
SynchronizationImple comp = new SynchronizationImple(new Synchronization());
assertTrue(comp.compareTo(sync) != 0);
assertTrue(sync.toString() != null);
}
use of com.arjuna.ats.internal.jta.resources.arjunacore.SynchronizationImple in project narayana by jbosstm.
the class SynchronizationUnitTest method testInvalid.
@Test
public void testInvalid() {
SynchronizationImple sync = new SynchronizationImple(null);
assertTrue(sync.get_uid().notEquals(Uid.nullUid()));
assertFalse(sync.beforeCompletion());
assertFalse(sync.afterCompletion(Status.STATUS_COMMITTED));
}
Aggregations