(self)
| 2118 | self.assertIs(self.callback_called, True) |
| 2119 | |
| 2120 | def test_pre_callback(self): |
| 2121 | def pre_hook(): |
| 2122 | pass |
| 2123 | |
| 2124 | transaction.on_commit(pre_hook, using="default") |
| 2125 | with self.captureOnCommitCallbacks() as callbacks: |
| 2126 | self.enqueue_callback() |
| 2127 | |
| 2128 | self.assertEqual(len(callbacks), 1) |
| 2129 | self.assertNotEqual(callbacks[0], pre_hook) |
| 2130 | |
| 2131 | @skipUnlessDBFeature("uses_savepoints") |
| 2132 | def test_with_rolled_back_savepoint(self): |
nothing calls this directly
no test coverage detected