2010-06-01 Michael Snyder <msnyder@vmware.com>
[deliverable/binutils-gdb.git] / gdb / testsuite / gdb.base / ena-dis-br.exp
index bbf8c517abe82eadbc69a0ee09d0d396a18e98b5..83d83c63ff6a9e8c3b592d49114659a07782ae8e 100644 (file)
@@ -1,21 +1,20 @@
 # This testcase is part of GDB, the GNU debugger.
 
-# Copyright 1997, 1998, 1999, 2003, 2004 Free Software Foundation,
-# Inc.
+# Copyright 1997, 1998, 1999, 2003, 2004, 2007, 2008, 2009, 2010
+# 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
-# the Free Software Foundation; either version 2 of the License, or
+# the Free Software Foundation; either version 3 of the License, or
 # (at your option) any later version.
-# 
+#
 # This program is distributed in the hope that it will be useful,
 # but WITHOUT ANY WARRANTY; without even the implied warranty of
 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 # GNU General Public License for more details.
-# 
+#
 # You should have received a copy of the GNU General Public License
-# along with this program; if not, write to the Free Software
-# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
+# along with this program.  If not, see <http://www.gnu.org/licenses/>.
 
 if $tracelevel then {
     strace $tracelevel
@@ -26,8 +25,6 @@ global usestubs
 #
 # test running programs
 #
-set prms_id 0
-set bug_id 0
 
 set testfile "break"
 set srcfile ${testfile}.c
@@ -35,15 +32,18 @@ set srcfile1 ${testfile}1.c
 set binfile ${objdir}/${subdir}/${testfile}
 
 if  { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}0.o" object {debug nowarnings}] != "" } {
-     gdb_suppress_entire_file "Testcase compile failed, so all tests in this file will automatically fail."
+     untested ena-dis-br.exp
+     return -1
 }
 
 if  { [gdb_compile "${srcdir}/${subdir}/${srcfile1}" "${binfile}1.o" object {debug nowarnings}] != "" } {
-     gdb_suppress_entire_file "Testcase compile failed, so all tests in this file will automatically fail."
+     untested ena-dis-br.exp
+     return -1
 }
 
 if  { [gdb_compile "${binfile}0.o ${binfile}1.o" "${binfile}" executable {debug nowarnings}] != "" } {
-     gdb_suppress_entire_file "Testcase compile failed, so all tests in this file will automatically fail."
+     untested ena-dis-br.exp
+     return -1
 }
 
 gdb_exit
@@ -84,7 +84,7 @@ proc break_at { breakpoint where } {
 
 set bp [break_at "marker1" " line ($bp_location15|$bp_location16)"]
 
-gdb_test "enable $bp" "" "enable break marker1"
+gdb_test_no_output "enable $bp" "enable break marker1"
 
 gdb_test "info break $bp" \
     "\[0-9\]*\[ \t\]+breakpoint\[ \t\]+keep\[ \t\]+y.*" \
@@ -102,13 +102,13 @@ gdb_test_multiple "continue" "$test" {
     }
 }
 
-gdb_test "delete $bp" "" "delete break marker1"
+gdb_test_no_output "delete $bp" "delete break marker1"
 
 # Verify that we can set a breakpoint to be self-disabling after the
 # first time it triggers.
 set bp [break_at "marker2" " line ($bp_location8|$bp_location9)"]
 
-gdb_test "enable once $bp" "" "enable once break marker2"
+gdb_test_no_output "enable once $bp" "enable once break marker2"
 
 gdb_test "info break $bp" \
     "\[0-9\]*\[ \t\]+breakpoint\[ \t\]+dis\[ \t\]+y.*" \
@@ -143,7 +143,7 @@ if ![runto_main] then {
 
 set bp [break_at "marker3" " line ($bp_location17|$bp_location18)"]
 
-gdb_test "enable del $bp" "" "enable del break marker3"
+gdb_test_no_output "enable del $bp" "enable del break marker3"
 
 gdb_test "info break $bp" \
     "\[0-9\]*\[ \t\]+breakpoint\[ \t\]+del\[ \t\]+y.*" \
@@ -162,7 +162,7 @@ gdb_test "info break $bp" \
 
 set bp [break_at "marker4" " line ($bp_location14|$bp_location13).*"]
 
-gdb_test "disable $bp" "" "disable break marker4"
+gdb_test_no_output "disable $bp" "disable break marker4"
 
 gdb_test "info break $bp" \
     "\[0-9\]*\[ \t\]+breakpoint\[ \t\]+keep\[ \t\]+n.*" \
@@ -237,7 +237,7 @@ gdb_test "ignore $bp 1" \
     "Will ignore next crossing of breakpoint \[0-9\]*.*" \
     "ignore break marker1"
 
-gdb_test "enable del $bp" "" "enable del break marker1"
+gdb_test_no_output "enable del $bp" "enable del break marker1"
 
 gdb_test "info break $bp" \
     "\[0-9\]*\[ \t\]+breakpoint\[ \t\]+del\[ \t\]+y.*ignore next 1 hits.*" \
@@ -263,7 +263,7 @@ gdb_test "ignore $bp 10" \
     "Will ignore next 10 crossings of breakpoint \[0-9\]*.*" \
     "ignore break marker1"
 
-gdb_test "disable $bp" "" "disable break marker1"
+gdb_test_no_output "disable $bp" "disable break marker1"
 
 gdb_continue_to_end "no stop at ignored & disabled break marker1"
 rerun_to_main
This page took 0.029505 seconds and 4 git commands to generate.