forked from OSchip/llvm-project
Add an expect() statement within breakpoint_conditions() method which tests that
the process status is indeed 'stopped' before invoking 'frame variable -t val' command to inspect the frame variable. When I run the test suite, it sometimes emits an output like: runCmd: frame variable -t val runCmd failed! error: you must be stopped in a valid stack frame to view frame variables. The expect() statement inserted is to make sure that the process is stopped and we have a valid frame. llvm-svn: 120318
This commit is contained in:
parent
ba3a8fa7ab
commit
c9ea0f8425
|
|
@ -56,6 +56,10 @@ class BreakpointConditionsTestCase(TestBase):
|
||||||
# Now run the program.
|
# Now run the program.
|
||||||
self.runCmd("run", RUN_SUCCEEDED)
|
self.runCmd("run", RUN_SUCCEEDED)
|
||||||
|
|
||||||
|
# The process should be stopped.
|
||||||
|
self.expect("process status", PROCESS_STOPPED,
|
||||||
|
patterns = ['Process .* stopped'])
|
||||||
|
|
||||||
# 'frame variable -t val' should return 3 due to breakpoint condition.
|
# 'frame variable -t val' should return 3 due to breakpoint condition.
|
||||||
self.expect("frame variable -t val", VARIABLES_DISPLAYED_CORRECTLY,
|
self.expect("frame variable -t val", VARIABLES_DISPLAYED_CORRECTLY,
|
||||||
startstr = '(int) val = 3')
|
startstr = '(int) val = 3')
|
||||||
|
|
|
||||||
|
|
@ -151,6 +151,8 @@ BREAKPOINT_HIT_THRICE = "Breakpoint resolved with hit cout = 3"
|
||||||
|
|
||||||
STEP_OUT_SUCCEEDED = "Thread step-out succeeded"
|
STEP_OUT_SUCCEEDED = "Thread step-out succeeded"
|
||||||
|
|
||||||
|
PROCESS_STOPPED = "Process status should be stopped"
|
||||||
|
|
||||||
STOPPED_DUE_TO_BREAKPOINT = "Process should be stopped due to breakpoint"
|
STOPPED_DUE_TO_BREAKPOINT = "Process should be stopped due to breakpoint"
|
||||||
|
|
||||||
STOPPED_DUE_TO_BREAKPOINT_WITH_STOP_REASON_AS = "%s, %s" % (
|
STOPPED_DUE_TO_BREAKPOINT_WITH_STOP_REASON_AS = "%s, %s" % (
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue