testsuite: ovldbreak.exp: fix regexp
[deliverable/binutils-gdb.git] / gdb / testsuite / gdb.threads / kill.exp
index 741ebd50d12b5b7dd0ff68039b63409866982747..82f221eef67e6eb7394a7253971a2ba07305bf9c 100644 (file)
@@ -1,6 +1,6 @@
 # This testcase is part of GDB, the GNU debugger.
 
-# Copyright 2014-2016 Free Software Foundation, Inc.
+# Copyright 2014-2018 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
@@ -21,7 +21,7 @@ standard_testfile
 # program and spawn several threads before trying to kill the program.
 
 proc test {threaded} {
-    global testfile srcfile
+    global testfile srcfile decimal
 
     with_test_prefix [expr ($threaded)?"threaded":"non-threaded"] {
 
@@ -48,7 +48,7 @@ proc test {threaded} {
        gdb_continue_to_breakpoint "break here" ".*break here.*"
 
        if {$threaded} {
-           gdb_test "info threads" "6.*5.*4.*3.*2.*1.*" "all threads started"
+           gdb_test "info threads" "1.*2.*3.*4.*5.*6.*" "all threads started"
        }
 
        # This kills and ensures no output other than the prompt comes out,
@@ -68,7 +68,11 @@ proc test {threaded} {
        #
        # the above would mean that the remote end crashed.
 
-       gdb_test "kill" "^y" "kill program" "Kill the program being debugged\\? \\(y or n\\) $" "y"
+       gdb_test_multiple "kill" "kill" {
+           -re "Kill the program being debugged\\? \\(y or n\\) $" {
+               gdb_test "y" "\\\[Inferior $decimal \\(.*\\) killed\\\]" "kill"
+           }
+       }
     }
 }
 
This page took 0.035203 seconds and 4 git commands to generate.