[Bash-completion-commits] [SCM] bash-completion branch, master, updated. bb47efd9b6d5717434d4d85c4a31bcd6787def97

Freddy Vulto fvulto at gmail.com
Sun Oct 4 16:23:41 UTC 2009


The following commit has been merged in the master branch:
commit bb47efd9b6d5717434d4d85c4a31bcd6787def97
Author: Freddy Vulto <fvulto at gmail.com>
Date:   Sun Oct 4 18:18:29 2009 +0200

    (testsuite) Allow trailing space on one completion
    Within `match_items', if only one completion is generated, an (optional)
    trailing space is allowed, because -o nospace might not be in effect.

diff --git a/test/lib/library.exp b/test/lib/library.exp
index 4ca6b96..05259d3 100644
--- a/test/lib/library.exp
+++ b/test/lib/library.exp
@@ -383,7 +383,8 @@ proc match_items {items test {size 20}} {
         }; # for
         if {[llength $items] == 1} {
             expect {
-                -re "^$expected$" { set result true }
+                # NOTE: The optional space ( ?) depends on whether -o nospace is active
+                -re "^$expected ?$" { set result true }
                 "\r\n" { set result false; break }
                 default { set result false; break }
                 timeout { set result false; break }

-- 
bash-completion



More information about the Bash-completion-commits mailing list