Commit 4dab3873 authored by Jason Madden's avatar Jason Madden

Add test for p_invalidate calling _p_deactivate.

parent ba3c0022
......@@ -1402,6 +1402,14 @@ class _Persistent_Base(object):
broken._p_changed = True
broken._p_changed = 0
def test_p_invalidate_calls_p_deactivate(self):
class P(self._getTargetClass()):
deactivated = False
def _p_deactivate(self):
self.deactivated = True
p = P()
p._p_invalidate()
self.assertTrue(p.deactivated)
class PyPersistentTests(unittest.TestCase, _Persistent_Base):
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment