aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--gdb/testsuite/gdb.base/branch-to-self.exp17
1 files changed, 16 insertions, 1 deletions
diff --git a/gdb/testsuite/gdb.base/branch-to-self.exp b/gdb/testsuite/gdb.base/branch-to-self.exp
index 9b4f746..71859d7 100644
--- a/gdb/testsuite/gdb.base/branch-to-self.exp
+++ b/gdb/testsuite/gdb.base/branch-to-self.exp
@@ -35,7 +35,22 @@ with_test_prefix "single-step" {
gdb_test "break ${testfile}.c:${line_num}" "Breakpoint .*" \
"set breakpoint"
gdb_continue_to_breakpoint "hit breakpoint"
- gdb_test "si" ".*${testfile}.c:${line_num}.*"
+
+ set stepi_count 1
+ gdb_test_multiple "stepi" "" {
+ -re -wrap ".*${testfile}.c:${line_num}.*" {
+ pass $gdb_test_name
+ }
+ -re -wrap "" {
+ if { $stepi_count == 10 } {
+ fail $gdb_test_name
+ } else {
+ incr stepi_count
+ send_gdb "stepi\n"
+ exp_continue
+ }
+ }
+ }
}
with_test_prefix "break-cond" {