diff options
author | Greg Clayton <gclayton@apple.com> | 2016-07-27 20:47:49 +0000 |
---|---|---|
committer | Greg Clayton <gclayton@apple.com> | 2016-07-27 20:47:49 +0000 |
commit | 8089e81ccde146f550852a595b98666d6fe01bbd (patch) | |
tree | 93c6480506f904f74e546310856c885de0bce063 /lldb/packages/Python/lldbsuite/test | |
parent | 94872ff11c9bb7d7d4c6523f62daf6b2366ad0f2 (diff) | |
download | bcm5719-llvm-8089e81ccde146f550852a595b98666d6fe01bbd.tar.gz bcm5719-llvm-8089e81ccde146f550852a595b98666d6fe01bbd.zip |
Fixed "void SBWatchpoint::SetEnabled (bool enabled)" to work properly and added a test for it.
https://llvm.org/bugs/show_bug.cgi?id=28729
<rdar://problem/27575225>
llvm-svn: 276914
Diffstat (limited to 'lldb/packages/Python/lldbsuite/test')
-rw-r--r-- | lldb/packages/Python/lldbsuite/test/functionalities/watchpoint/watchpoint_events/TestWatchpointEvents.py | 16 |
1 files changed, 11 insertions, 5 deletions
diff --git a/lldb/packages/Python/lldbsuite/test/functionalities/watchpoint/watchpoint_events/TestWatchpointEvents.py b/lldb/packages/Python/lldbsuite/test/functionalities/watchpoint/watchpoint_events/TestWatchpointEvents.py index fdeb4b8fa3b..f8435befae5 100644 --- a/lldb/packages/Python/lldbsuite/test/functionalities/watchpoint/watchpoint_events/TestWatchpointEvents.py +++ b/lldb/packages/Python/lldbsuite/test/functionalities/watchpoint/watchpoint_events/TestWatchpointEvents.py @@ -64,17 +64,23 @@ class TestWatchpointEvents (TestBase): if not error.Success(): self.fail ("Failed to make watchpoint for local_var: %s"%(error.GetCString())) - self.GetWatchpointEvent (lldb.eWatchpointEventTypeAdded) + self.GetWatchpointEvent(lldb.eWatchpointEventTypeAdded) # Now change some of the features of this watchpoint and make sure we get events: local_watch.SetEnabled(False) - self.GetWatchpointEvent (lldb.eWatchpointEventTypeDisabled) + self.GetWatchpointEvent(lldb.eWatchpointEventTypeDisabled) + + local_watch.SetEnabled(True) + self.GetWatchpointEvent(lldb.eWatchpointEventTypeEnabled) local_watch.SetIgnoreCount(10) - self.GetWatchpointEvent (lldb.eWatchpointEventTypeIgnoreChanged) + self.GetWatchpointEvent(lldb.eWatchpointEventTypeIgnoreChanged) - local_watch.SetCondition ("1 == 2") - self.GetWatchpointEvent (lldb.eWatchpointEventTypeConditionChanged) + condition = "1 == 2" + local_watch.SetCondition(condition) + self.GetWatchpointEvent(lldb.eWatchpointEventTypeConditionChanged) + self.assertTrue(local_watch.GetCondition() == condition, 'make sure watchpoint condition is "' + condition + '"'); + def GetWatchpointEvent (self, event_type): # We added a watchpoint so we should get a watchpoint added event. event = lldb.SBEvent() |