[Lldb-commits] [lldb] e3a0283 - [lldb/Test] Fix replay with TestSetWatchpoint.py
Jonas Devlieghere via lldb-commits
lldb-commits at lists.llvm.org
Thu May 21 20:35:40 PDT 2020
Author: Jonas Devlieghere
Date: 2020-05-21T20:35:32-07:00
New Revision: e3a0283e5a3f7eccd82c7e090188926723e8d8c9
URL: https://github.com/llvm/llvm-project/commit/e3a0283e5a3f7eccd82c7e090188926723e8d8c9
DIFF: https://github.com/llvm/llvm-project/commit/e3a0283e5a3f7eccd82c7e090188926723e8d8c9.diff
LOG: [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.
Added:
Modified:
lldb/test/API/python_api/watchpoint/TestSetWatchpoint.py
Removed:
################################################################################
diff --git a/lldb/test/API/python_api/watchpoint/TestSetWatchpoint.py b/lldb/test/API/python_api/watchpoint/TestSetWatchpoint.py
index a34806d16579..49ecf7aee39c 100644
--- a/lldb/test/API/python_api/watchpoint/TestSetWatchpoint.py
+++ b/lldb/test/API/python_api/watchpoint/TestSetWatchpoint.py
@@ -103,4 +103,9 @@ def test_watch_val(self):
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())
More information about the lldb-commits
mailing list