Fix TUI test suite regexps
authorTom Tromey <tom@tromey.com>
Thu, 12 Dec 2019 02:17:47 +0000 (19:17 -0700)
committerTom Tromey <tom@tromey.com>
Thu, 12 Dec 2019 02:19:13 +0000 (19:19 -0700)
Testing on another TUI series showed that some of the regexps in the
TUI test suite have been incorrect for a while.  In particular, "|"
was meant literally in these tests, but was interpreted as pattern
alternation due to lack of quoting.

This patch fixes the bad tests.  I am checking this in.

gdb/testsuite/ChangeLog
2019-12-11  Tom Tromey  <tom@tromey.com>

* gdb.tui/resize.exp: Fix regexp.
* gdb.tui/regs.exp: Fix regexps.
* gdb.tui/main.exp: Fix regexp.

Change-Id: Ib6661361171ac120bb92f4a8aec7efa4bcaa36b9

gdb/testsuite/ChangeLog
gdb/testsuite/gdb.tui/main.exp
gdb/testsuite/gdb.tui/regs.exp
gdb/testsuite/gdb.tui/resize.exp

index cf3fcb7b9b08fbfb9477704dc24bec485f05e299..b31e8dd61154667de37a6ac0a9cd5b9a2cf8f062 100644 (file)
@@ -1,3 +1,9 @@
+2019-12-11  Tom Tromey  <tom@tromey.com>
+
+       * gdb.tui/resize.exp: Fix regexp.
+       * gdb.tui/regs.exp: Fix regexps.
+       * gdb.tui/main.exp: Fix regexp.
+
 2019-12-11  Tom Tromey  <tom@tromey.com>
 
        * gdb.tui/resize.exp: Update.
index eab28deb15d8b8e325a1c296734a794f81703d11..57ddb52bf366347c18d1bc04a403571e42d348c5 100644 (file)
@@ -31,4 +31,4 @@ if {![Term::enter_tui]} {
 }
 
 Term::command "file [standard_output_file $testfile]"
-Term::check_contents "show main after file" ">|21 *return 0"
+Term::check_contents "show main after file" "\\|.*21 *return 0"
index dcecd03af9affa88c848f87c1cbdb64e780376b1..d0114a2a2305def77a20b2c55a7c1463df636812 100644 (file)
@@ -34,7 +34,7 @@ if {![Term::enter_tui]} {
     unsupported "TUI not supported"
 }
 
-Term::check_contents "source at startup" ">|21 *return 0"
+Term::check_contents "source at startup" "\\|.*21 *return 0"
 
 Term::command "layout regs"
 Term::check_box "register box" 0 0 80 7
@@ -42,4 +42,4 @@ Term::check_box "source box in regs layout" 0 6 80 9
 
 set text [Term::get_line 1]
 # Just check for any register window content at all.
-Term::check_contents "any register contents" "^|.*\[^ \].*|$"
+Term::check_contents "any register contents" "\\|.*\[^ \].*\\|"
index c5302799ea50ae6c28e5aed68d642e22720e4e76..d210aaa74c2f698514a12b56ac73aa0d10d263fd 100644 (file)
@@ -34,7 +34,7 @@ if {![Term::enter_tui]} {
     unsupported "TUI not supported"
 }
 
-Term::check_contents "source at startup" ">|21 *return 0"
+Term::check_contents "source at startup" "\\|.*21 *return 0"
 
 Term::resize 40 90
 Term::check_box "source box after resize" 0 0 90 26
This page took 0.031275 seconds and 4 git commands to generate.