]> git.ipfire.org Git - thirdparty/binutils-gdb.git/blobdiff - gdb/testsuite/gdb.base/foll-exec.exp
Fix some duplicate test names
[thirdparty/binutils-gdb.git] / gdb / testsuite / gdb.base / foll-exec.exp
index f496ccaf411145d6a0c4850696ec63f2d44a48d7..b0e155dd379e01f9dd2b8237beadf7323586a4ab 100644 (file)
@@ -1,4 +1,4 @@
-#   Copyright 1997-2016 Free Software Foundation, Inc.
+#   Copyright 1997-2020 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
@@ -32,12 +32,12 @@ set compile_options debug
 
 # build the first test case
 if  { [gdb_compile "${srcdir}/${subdir}/${srcfile2}" "${binfile2}" executable $compile_options] != "" } {
-     untested foll-exec.exp
+     untested "failed to compile"
      return -1
 }
 
 if  { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable $compile_options] != "" } {
-     untested foll-exec.exp
+     untested "failed to compile"
      return -1
 }
 
@@ -48,7 +48,7 @@ proc do_exec_tests {} {
    # Start the program running, and stop at main.
    #
    if ![runto_main] then {
-     fail "Couldn't run ${testfile}"
+     fail "couldn't run ${testfile}"
      return
    }
 
@@ -75,13 +75,16 @@ proc do_exec_tests {} {
    # Start the program running, and stop at main.
    #
    if ![runto_main] then {
-     fail "Couldn't run ${testfile}"
+     fail "couldn't run ${testfile}"
      return
    }
-   # Execute the code setting up variable PROG.
-   set tbreak_line [gdb_get_line_number " tbreak-execlp " $srcfile]
-   gdb_test "tbreak ${tbreak_line}"
-   gdb_continue_to_breakpoint "line tbreak-execlp" ".*execlp \\(.*"
+
+   with_test_prefix "1st run" {
+       # Execute the code setting up variable PROG.
+       set tbreak_line [gdb_get_line_number " tbreak-execlp " $srcfile]
+       gdb_test "tbreak ${tbreak_line}" "" "insert breakpoint"
+       gdb_continue_to_breakpoint "line tbreak-execlp" ".*execlp \\(.*"
+   }
 
    # Verify that we can see various global and local variables
    # in this program, and that they have expected values.  Some
@@ -162,7 +165,7 @@ proc do_exec_tests {} {
    # Start the program running, and stop at main.
    #
    if ![runto_main] then {
-     fail "Couldn't run ${testfile} (2nd try)"
+     fail "couldn't run ${testfile} (2nd try)"
      return
    }
 
@@ -231,13 +234,16 @@ proc do_exec_tests {} {
    # Start the program running, and stop at main.
    #
    if ![runto_main] then {
-     fail "Couldn't run ${testfile} (3rd try)"
+     fail "couldn't run ${testfile} (3rd try)"
      return
    }
-   # Execute the code setting up variable PROG.
-   set tbreak_line [gdb_get_line_number " tbreak-execlp " $srcfile]
-   gdb_test "tbreak ${tbreak_line}"
-   gdb_continue_to_breakpoint "line tbreak-execlp" ".*execlp \\(.*"
+
+   with_test_prefix "2nd run" {
+       # Execute the code setting up variable PROG.
+       set tbreak_line [gdb_get_line_number " tbreak-execlp " $srcfile]
+       gdb_test "tbreak ${tbreak_line}" "" "insert breakpoint"
+       gdb_continue_to_breakpoint "line tbreak-execlp" ".*execlp \\(.*"
+   }
 
    # Verify that we can follow through follow an execl()
    # call.  (We must jump around earlier exec* calls.)
@@ -296,13 +302,16 @@ proc do_exec_tests {} {
    # Start the program running, and stop at main.
    #
    if ![runto_main] then {
-     fail "Couldn't run ${testfile} (4th try)"
+     fail "couldn't run ${testfile} (4th try)"
      return
    }
-   # Execute the code setting up variable PROG.
-   set tbreak_line [gdb_get_line_number " tbreak-execlp " $srcfile]
-   gdb_test "tbreak ${tbreak_line}"
-   gdb_continue_to_breakpoint "line tbreak-execlp" ".*execlp \\(.*"
+
+   with_test_prefix "3rd run" {
+       # Execute the code setting up variable PROG.
+       set tbreak_line [gdb_get_line_number " tbreak-execlp " $srcfile]
+       gdb_test "tbreak ${tbreak_line}" "" "insert breakpoint"
+       gdb_continue_to_breakpoint "line tbreak-execlp" ".*execlp \\(.*"
+   }
 
    # Verify that we can follow through follow an execv()
    # call.  (We must jump around earlier exec* calls.)
@@ -355,7 +364,7 @@ proc do_exec_tests {} {
    # Start the program running, and stop at main.
    #
    if ![runto_main] then {
-     fail "Couldn't run ${testfile} (5th try)"
+     fail "couldn't run ${testfile} (5th try)"
      return
    }