Ejemplo n.º 1
0
 /** Test 20 */
 public void testReadWriteReleaseCheckRead() {
   assertTrue(lockManager.readLock(tx2, obj, testIsoLevel));
   assertTrue(lockManager.writeLock(tx2, obj, testIsoLevel));
   assertTrue(lockManager.hasRead(tx2, obj));
   assertTrue(lockManager.releaseLock(tx2, obj));
   assertFalse(lockManager.hasRead(tx2, obj));
 }
Ejemplo n.º 2
0
 public void tearDown() throws Exception {
   // restore isolation level
   cld.setIsolationLevel(oldIsolationLevel);
   try {
     lockManager.releaseLock(tx1, obj);
     lockManager.releaseLock(tx2, obj);
   } finally {
     super.tearDown();
   }
 }
Ejemplo n.º 3
0
 /** Test 17 */
 public void testReleaseWriteLock() {
   assertTrue(lockManager.writeLock(tx1, obj, testIsoLevel));
   assertTrue(lockManager.releaseLock(tx1, obj));
   assertTrue(lockManager.writeLock(tx2, obj, testIsoLevel));
 }