Example #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))
Example #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))
Example #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))
Example #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))
Example #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))
Example #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))
Example #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))
Example #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))