[lldb/Test] Fix replay with TestSetWatchpoint.py

The reproducers only track the creation of objects and not their
destruction. Therefore it keeps all objects alive indefinitely.
This commit is contained in:
Jonas Devlieghere 2020-05-21 20:34:39 -07:00
parent 5127d4b4ff
commit e3a0283e5a
1 changed files with 6 additions and 1 deletions

View File

@ -103,4 +103,9 @@ class SetWatchpointAPITestCase(TestBase):
PROCESS_EXITED)
self.dbg.DeleteTarget(target)
self.assertFalse(watchpoint.IsValid())
# The next check relies on the watchpoint being destructed, which does
# not happen during replay because objects are intentionally kept alive
# forever.
if not configuration.is_reproducer():
self.assertFalse(watchpoint.IsValid())