예제 #1
0
 def testAbortCallsAbort(self):
     target = Target()
     registry.register(target)
     transaction.abort()
     self.failUnless(target.abort_called)
     # _abort removes the TM from the registry
     self.failIf(registry.contains(target))
예제 #2
0
 def testAbortCallsAbort(self):
     target = Target()
     registry.register(target)
     transaction.abort()
     self.failUnless(target.abort_called)
     # _abort removes the TM from the registry
     self.failIf(registry.contains(target))
예제 #3
0
 def testCommitCallsFinish(self):
     target = Target()
     registry.register(target)
     transaction.commit()
     self.failUnless(target.finish_called)
     # _finish removes the TM from the registry
     self.failIf(registry.contains(target))
예제 #4
0
 def testCommitCallsFinish(self):
     target = Target()
     registry.register(target)
     transaction.commit()
     self.failUnless(target.finish_called)
     # _finish removes the TM from the registry
     self.failIf(registry.contains(target))
예제 #5
0
 def testAbortIsForwarded(self):
     target = Target()
     registry.register(target)
     tm = registry.get(target)
     tm._abort()
     self.failUnless(target.abort_called)
     # _abort removes the TM from the registry
     self.failIf(registry.contains(target))
예제 #6
0
 def testFinishIsForwarded(self):
     target = Target()
     registry.register(target)
     tm = registry.get(target)
     tm._finish()
     self.failUnless(target.finish_called)
     # _finish removes the TM from the registry
     self.failIf(registry.contains(target))
예제 #7
0
 def testAbortIsForwarded(self):
     target = Target()
     registry.register(target)
     tm = registry.get(target)
     tm._abort()
     self.failUnless(target.abort_called)
     # _abort removes the TM from the registry
     self.failIf(registry.contains(target))
예제 #8
0
 def testFinishIsForwarded(self):
     target = Target()
     registry.register(target)
     tm = registry.get(target)
     tm._finish()
     self.failUnless(target.finish_called)
     # _finish removes the TM from the registry
     self.failIf(registry.contains(target))
예제 #9
0
 def testBeginIsForwarded(self):
     target = Target()
     registry.register(target)
     tm = registry.get(target)
     tm._begin()
     self.failUnless(target.begin_called)
예제 #10
0
 def testBeginIsForwarded(self):
     target = Target()
     registry.register(target)
     tm = registry.get(target)
     tm._begin()
     self.failUnless(target.begin_called)