aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPedro Alves <palves@redhat.com>2012-02-02 18:09:07 +0000
committerPedro Alves <palves@redhat.com>2012-02-02 18:09:07 +0000
commitc0b9f2c6e8ec5c960dea8ee7d60d8afb9a9367f8 (patch)
tree300a4fa9473f1aecd017199e01a3af24887e058c
parent5f8cefd757a922ae0e5846d712d27d4650a4386b (diff)
downloadgdb-c0b9f2c6e8ec5c960dea8ee7d60d8afb9a9367f8.zip
gdb-c0b9f2c6e8ec5c960dea8ee7d60d8afb9a9367f8.tar.gz
gdb-c0b9f2c6e8ec5c960dea8ee7d60d8afb9a9367f8.tar.bz2
2012-02-02 Pedro Alves <palves@redhat.com>
* gdb.gdb/complaints.exp: Skip if gdb,noinferiorio is set. * gdb.gdb/selftest.exp (test_with_self): Handle gdb,noinferiorio.
-rw-r--r--gdb/testsuite/ChangeLog5
-rw-r--r--gdb/testsuite/gdb.gdb/complaints.exp5
-rw-r--r--gdb/testsuite/gdb.gdb/selftest.exp30
3 files changed, 30 insertions, 10 deletions
diff --git a/gdb/testsuite/ChangeLog b/gdb/testsuite/ChangeLog
index b036df4..573ecbe 100644
--- a/gdb/testsuite/ChangeLog
+++ b/gdb/testsuite/ChangeLog
@@ -1,5 +1,10 @@
2012-02-02 Pedro Alves <palves@redhat.com>
+ * gdb.gdb/complaints.exp: Skip if gdb,noinferiorio is set.
+ * gdb.gdb/selftest.exp (test_with_self): Handle gdb,noinferiorio.
+
+2012-02-02 Pedro Alves <palves@redhat.com>
+
* gdb.base/term.exp: Rewrite.
* gdb.base/term.c: New.
diff --git a/gdb/testsuite/gdb.gdb/complaints.exp b/gdb/testsuite/gdb.gdb/complaints.exp
index 5ec02ff..97a3270 100644
--- a/gdb/testsuite/gdb.gdb/complaints.exp
+++ b/gdb/testsuite/gdb.gdb/complaints.exp
@@ -23,6 +23,11 @@ if { [is_remote target] || ![isnative] } then {
return
}
+if [target_info exists gdb,noinferiorio] {
+ verbose "Skipping because of no inferiorio capabilities."
+ return
+}
+
proc setup_test { executable } {
global gdb_prompt
global timeout
diff --git a/gdb/testsuite/gdb.gdb/selftest.exp b/gdb/testsuite/gdb.gdb/selftest.exp
index 21798bc..1ffa945 100644
--- a/gdb/testsuite/gdb.gdb/selftest.exp
+++ b/gdb/testsuite/gdb.gdb/selftest.exp
@@ -394,19 +394,29 @@ proc test_with_self { executable } {
}
# start the "xgdb" process
- gdb_test_multiple "continue" "xgdb is at prompt" {
- -re "GNU gdb \[0-9\.\]*.*Copyright \\(C\\) \[0-9\]* Free Software Foundation, Inc.*License GPLv3\\+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>.*This is free software: you are free to change and redistribute it.*There is NO WARRANTY, to the extent permitted by law. Type \"show copying\".*and \"show warranty\" for details.*This GDB was configured as .*$gdb_prompt $" {
- pass "xgdb is at prompt"
+ if [target_info exists gdb,noinferiorio] {
+ # Maybe testing with a local extended-remote gdbserver. With
+ # no way to interact with inferior GDB, all we can do is let
+ # it run.
+ send_gdb "continue\n"
+ # Wait a bit while the inferior gdb gets to its prompt.
+ sleep 1
+ } else {
+ set test "xgdb is at prompt"
+ gdb_test_multiple "continue" $test {
+ -re "GNU gdb \[0-9\.\]*.*Copyright \\(C\\) \[0-9\]* Free Software Foundation, Inc.*License GPLv3\\+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>.*This is free software: you are free to change and redistribute it.*There is NO WARRANTY, to the extent permitted by law. Type \"show copying\".*and \"show warranty\" for details.*This GDB was configured as .*$gdb_prompt $" {
+ pass $test
+ }
}
- }
-
- # set xgdb prompt so we can tell which is which
- gdb_test_multiple "set prompt (xgdb) " "Set xgdb_prompt" {
- -re "\[(\]xgdb\[)\].*\[(\]xgdb\[)\] $" {
- pass "Set xgdb prompt"
+
+ # set xgdb prompt so we can tell which is which
+ gdb_test_multiple "set prompt (xgdb) " "Set xgdb_prompt" {
+ -re "\[(\]xgdb\[)\].*\[(\]xgdb\[)\] $" {
+ pass "Set xgdb prompt"
+ }
}
}
-
+
# kill the xgdb process
set description "send ^C to child process"
send_gdb "\003"