Fix failure in gdb.ada/complete.exp
authorTom Tromey <tromey@adacore.com>
Tue, 28 May 2019 16:55:59 +0000 (10:55 -0600)
committerTom Tromey <tromey@adacore.com>
Wed, 29 May 2019 16:06:13 +0000 (10:06 -0600)
I noticed a failure in gdb.ada/complete.exp when testing locally:

    FAIL: gdb.ada/complete.exp: complete break ada

This failed due to this output:

    [...]
    break ada/generated/gnatvsn.ads
    break ada/libgnat/s-excmac.ads
    break ada/sdefault.adb
    break ada/snames.adb
    break ada/snames.ads

This patch updates the regexp to allow "/" and "-" to appear.

gdb/testsuite/ChangeLog
2019-05-29  Tom Tromey  <tromey@adacore.com>

* gdb.ada/complete.exp (test_gdb_no_completion): Add "/" and "-"
to "break complete ada" test case's regexp.

gdb/testsuite/ChangeLog
gdb/testsuite/gdb.ada/complete.exp

index ddcb8346e436b378899b8777bc9c6cde8e106c14..661c93860ca89a6cdae53a5a36f111c96ee05b1e 100644 (file)
@@ -1,3 +1,8 @@
+2019-05-29  Tom Tromey  <tromey@adacore.com>
+
+       * gdb.ada/complete.exp (test_gdb_no_completion): Add "/" and "-"
+       to "break complete ada" test case's regexp.
+
 2019-05-29  Tom Tromey  <tromey@adacore.com>
 
        PR c++/20020:
index 8a5ef89dddbbd8a96f6eef549a7bf734c74affc0..1746c18463d1921ef8a749009f012428fae5c66b 100644 (file)
@@ -212,13 +212,14 @@ test_gdb_complete "ambiguous_func" \
 # However, we want to sanity-check each one of them, knowing that
 # each result should start with "break ada" and that the proposed
 # completion should look like a valid symbol name (in particular,
-# no uppercase letters...).  See gdb/22670.
+# no uppercase letters...).  See gdb/22670.  File names are OK as
+# well, which is why "/" and "-" appear in the regexp.
 
 gdb_test_no_output "set max-completions unlimited"
 
 set test "complete break ada"
 gdb_test_multiple "$test" $test {
-    -re "^$test$eol\(break ada(\[a-z0-9._@\])*$eol\)+$gdb_prompt $" {
+    -re "^$test$eol\(break ada\[-a-z0-9._@/\]*$eol\)+$gdb_prompt $" {
         pass $test
     }
     -re "\[A-Z\].*$gdb_prompt $" {
This page took 0.033522 seconds and 4 git commands to generate.