Clarify "list" output when specified lines are ambiguous
[deliverable/binutils-gdb.git] / gdb / testsuite / gdb.base / unwindonsignal.exp
index 774dd6de1cb83ef158e2b8aa499bc1ca830b1b3b..54024ff6124ac77ac9dc1725a50874c25224cc5f 100644 (file)
@@ -1,4 +1,4 @@
-# Copyright 2008-2014 Free Software Foundation, Inc.
+# Copyright 2008-2017 Free Software Foundation, Inc.
 
 # This program is free software; you can redistribute it and/or modify
 # it under the terms of the GNU General Public License as published by
 # You should have received a copy of the GNU General Public License
 # along with this program.  If not, see <http://www.gnu.org/licenses/>.
 
-if [target_info exists gdb,noinferiorio] {
-    verbose "Skipping unwindonsignal.exp because of no fileio capabilities."
-    continue
-}
-
 if [target_info exists gdb,nosignals] {
     verbose "Skipping unwindonsignal.exp because of nosignals."
     continue
@@ -27,20 +22,18 @@ if [target_info exists gdb,nosignals] {
 # Some targets can't do function calls, so don't even bother with this
 # test.
 if [target_info exists gdb,cannot_call_functions] {
-    setup_xfail "*-*-*" 2416
-    fail "This target can not call functions"
+    unsupported "this target can not call functions"
     continue
 }
 
 standard_testfile
 
-if {[prepare_for_testing $testfile.exp $testfile $srcfile debug]} {
-    untested $testfile.exp
+if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} {
     return -1
 }
 
 if { ![runto_main] } {
-    fail "Can't run to main"
+    fail "can't run to main"
     return 0
 }
 
@@ -58,15 +51,10 @@ gdb_test "show unwindonsignal" \
 
 # Call function (causing the program to get a signal), and see if gdb handles
 # it properly.
-gdb_test_multiple "call gen_signal ()" \
-       "unwindonsignal, inferior function call signaled" {
-    -re "\[\r\n\]*no signal\[\r\n\]+$gdb_prompt $" {
-       unsupported "unwindonsignal, inferior function call signaled"
-       return 0
-    }
-    -re "\[\r\n\]*The program being debugged was signaled.*\[\r\n\]+$gdb_prompt $" {
-       pass "unwindonsignal, inferior function call signaled"
-    }
+if {[gdb_test "call gen_signal ()"  \
+        "\[\r\n\]*The program being debugged was signaled.*" \
+        "unwindonsignal, inferior function call signaled"] != 0} {
+    return 0
 }
 
 # Verify the stack got unwound.
This page took 0.028255 seconds and 4 git commands to generate.