Search in sources :

Example 6 with BasicRecord

use of com.hp.mwtests.ts.arjuna.resources.BasicRecord in project narayana by jbosstm.

the class OnePhaseCommitUnitTest method testFailed.

@Test
public void testFailed() throws Exception {
    AtomicAction A = new AtomicAction();
    OnePhaseAbstractRecord rec1 = new OnePhaseAbstractRecord();
    BasicRecord rec2 = new BasicRecord();
    A.begin();
    A.add(rec1);
    A.add(rec2);
    A.commit();
    assertTrue(!rec1.onePhaseCalled());
}
Also used : AtomicAction(com.arjuna.ats.arjuna.AtomicAction) OnePhaseAbstractRecord(com.hp.mwtests.ts.arjuna.resources.OnePhaseAbstractRecord) BasicRecord(com.hp.mwtests.ts.arjuna.resources.BasicRecord) Test(org.junit.Test)

Aggregations

BasicRecord (com.hp.mwtests.ts.arjuna.resources.BasicRecord)6 AtomicAction (com.arjuna.ats.arjuna.AtomicAction)5 Test (org.junit.Test)5 LogStore (com.arjuna.ats.internal.arjuna.objectstore.LogStore)3 Uid (com.arjuna.ats.arjuna.common.Uid)2 RecoverAtomicAction (com.arjuna.ats.arjuna.recovery.RecoverAtomicAction)2 DummyHeuristic (com.hp.mwtests.ts.arjuna.resources.DummyHeuristic)1 HeuristicRecord (com.hp.mwtests.ts.arjuna.resources.HeuristicRecord)1 OnePhaseAbstractRecord (com.hp.mwtests.ts.arjuna.resources.OnePhaseAbstractRecord)1