aboutsummaryrefslogtreecommitdiff
path: root/gdb/testsuite/gdb.base
diff options
context:
space:
mode:
authorJason Molenda <jmolenda@apple.com>2000-02-05 07:30:26 +0000
committerJason Molenda <jmolenda@apple.com>2000-02-05 07:30:26 +0000
commitdfcd3bfb6f8a213007c20e60060b4e9ec9205205 (patch)
treec43f1f196f08266345d283414914033ecc50bd5e /gdb/testsuite/gdb.base
parent32edc927faea39b1f7be4654f6ffa03f3e6b16ce (diff)
downloadgdb-dfcd3bfb6f8a213007c20e60060b4e9ec9205205.zip
gdb-dfcd3bfb6f8a213007c20e60060b4e9ec9205205.tar.gz
gdb-dfcd3bfb6f8a213007c20e60060b4e9ec9205205.tar.bz2
import gdb-2000-02-04 snapshot
Diffstat (limited to 'gdb/testsuite/gdb.base')
-rw-r--r--gdb/testsuite/gdb.base/condbreak.exp34
-rw-r--r--gdb/testsuite/gdb.base/ptype.exp3
-rw-r--r--gdb/testsuite/gdb.base/step-test.exp12
-rw-r--r--gdb/testsuite/gdb.base/watchpoint.exp8
4 files changed, 31 insertions, 26 deletions
diff --git a/gdb/testsuite/gdb.base/condbreak.exp b/gdb/testsuite/gdb.base/condbreak.exp
index 0d4731f..2d40a0e 100644
--- a/gdb/testsuite/gdb.base/condbreak.exp
+++ b/gdb/testsuite/gdb.base/condbreak.exp
@@ -196,23 +196,21 @@ gdb_expect {
}
}
-#
# run until the breakpoint at marker2
-#
+# Same issues here as above.
setup_xfail hppa2.0w-*-* 11512CLLbs
-gdb_test "continue" "Continuing\\..*Breakpoint \[0-9\]+, marker2 \\(a=43\\) at .*$srcfile:4\[49\].*4\[49\]\[\t \]+.*" \
- "run until breakpoint at marker2"
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+send_gdb "continue\n"
+gdb_expect {
+ -re "Continuing\\..*Breakpoint \[0-9\]+, marker2 \\(a=43\\) at .*$srcfile:4\[49\].*4\[49\]\[\t \]+.*" {
+ pass "run until breakpoint at marker2"
+ }
+ -re "Continuing\\..*Breakpoint \[0-9\]+, $hex in marker2 \\(a=43\\) at .*$srcfile:4\[49\].*4\[49\]\[\t \]+.*" {
+ xfail "run until breakpoint at marker2"
+ }
+ -re "$gdb_prompt $" {
+ fail "run until breakpoint at marker2"
+ }
+ timeout {
+ fail "(timeout) run until breakpoint at marker2"
+ }
+}
diff --git a/gdb/testsuite/gdb.base/ptype.exp b/gdb/testsuite/gdb.base/ptype.exp
index f5b4503..82bf7df 100644
--- a/gdb/testsuite/gdb.base/ptype.exp
+++ b/gdb/testsuite/gdb.base/ptype.exp
@@ -132,6 +132,9 @@ if {!$gcc_compiled && !$hp_aCC_compiler} {
setup_xfail "rs6000-*-*" "i*86-*-sysv4*"
setup_xfail "hppa*-*-*" CLLbs14773
}
+
+# For get_debug_format to do its job, we need to have a current source file.
+gdb_test "list main" ""
get_debug_format
setup_xfail_format "DWARF 1"
gdb_test "whatis v_boolean" "type = (enum |)boolean" \
diff --git a/gdb/testsuite/gdb.base/step-test.exp b/gdb/testsuite/gdb.base/step-test.exp
index c0acf81..47d4572 100644
--- a/gdb/testsuite/gdb.base/step-test.exp
+++ b/gdb/testsuite/gdb.base/step-test.exp
@@ -142,13 +142,17 @@ test_i "stepi to next line" "stepi" \
test_i "stepi into function" "stepi" \
".*${decimal}.*callee.*STEPI" \
".*callee \\(\\) at .*step-test\\.c"
-test_i "stepi to function first line" "stepi" \
- ".*int callee\\(\\) .*\\{" \
- ".*myglob.*"
+
+# Continue to step until we reach the function's body. This makes it
+# more likely that we've actually completed the prologue, so "finish"
+# will work.
+test_i "stepi into function's first source line" "stepi" \
+ ".*${decimal}.*int callee" \
+ ".*${decimal}.*myglob.*; return 0;"
+
# Have to be careful here, if the finish does not work,
# then we may run to the end of the program, which
# will cause erroneous failures in the rest of the tests
-
send_gdb "finish\n"
gdb_expect {
-re ".*(Program received|Program exited).*$gdb_prompt $" {
diff --git a/gdb/testsuite/gdb.base/watchpoint.exp b/gdb/testsuite/gdb.base/watchpoint.exp
index 39c388e..3bd3314 100644
--- a/gdb/testsuite/gdb.base/watchpoint.exp
+++ b/gdb/testsuite/gdb.base/watchpoint.exp
@@ -406,7 +406,7 @@ proc test_stepping {} {
-re "Run.*exit from.*marker1.* at" {
pass "finish from marker1"
}
- default { fail "finish from marker1" ; return }
+ default { fail "finish from marker1 (timeout)" ; return }
}
gdb_expect {
@@ -415,12 +415,12 @@ proc test_stepping {} {
exp_continue
}
-re "func1 \\(\\);.*$gdb_prompt $" {
- pass "finish from marker1"
+ pass "back at main from marker1"
}
-re ".*$gdb_prompt $" {
- fail "finish from marker1"
+ fail "back at main from marker1"
}
- default { fail "finish from marker1 (timeout)" ; return }
+ default { fail "back at main from marker1 (timeout)" ; return }
}
gdb_test "next" "for \\(count = 0.*" "next to `for' in watchpoint.exp"