From: Marek Polacek Date: Fri, 30 Sep 2011 15:07:33 +0000 (+0000) Subject: gdb.python/python.exp: fix up race X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=c5cb204fbbdc0207d7aa1dd9b7fc5ba807fc3d58;p=binutils-gdb.git gdb.python/python.exp: fix up race --- diff --git a/gdb/testsuite/ChangeLog b/gdb/testsuite/ChangeLog index 6361dba6249..b5b40ef0a05 100644 --- a/gdb/testsuite/ChangeLog +++ b/gdb/testsuite/ChangeLog @@ -1,3 +1,8 @@ +2011-09-30 Marek Polacek + + * gdb.python/python.exp (verify pagination beforehand) + (verify pagination afterwards): Fix race by splitting the line. + 2011-09-29 Joseph Myers * lib/gdb.exp (is_amd64_regs_target, is_x86_like_target): Allow diff --git a/gdb/testsuite/gdb.python/python.exp b/gdb/testsuite/gdb.python/python.exp index 4da3c888704..ee39dbad518 100644 --- a/gdb/testsuite/gdb.python/python.exp +++ b/gdb/testsuite/gdb.python/python.exp @@ -106,7 +106,13 @@ gdb_test_no_output "set height $lines" set test "verify pagination beforehand" gdb_test_multiple "python print \"\\n\" * $lines" $test { - -re "---Type to continue, or q to quit---$" { + -re "---Type " { + exp_continue + } + -re " to continue, or q " { + exp_continue + } + -re " to quit---$" { pass $test } } @@ -116,7 +122,13 @@ gdb_test "python if gdb.execute('python print \"\\\\n\" * $lines', to_string=Tru set test "verify pagination afterwards" gdb_test_multiple "python print \"\\n\" * $lines" $test { - -re "---Type to continue, or q to quit---$" { + -re "---Type " { + exp_continue + } + -re " to continue, or q " { + exp_continue + } + -re " to quit---$" { pass $test } }