diff options
Diffstat (limited to 'test/lib/library.exp')
-rw-r--r-- | test/lib/library.exp | 32 |
1 files changed, 0 insertions, 32 deletions
diff --git a/test/lib/library.exp b/test/lib/library.exp index 899d74b6..c90c927c 100644 --- a/test/lib/library.exp +++ b/test/lib/library.exp @@ -378,37 +378,6 @@ proc assert_complete_dir {expected cmd dir {test ""} {args {}}} { -# Make sure a partial argument is completed. -# A completion is tried with `$partial', or if this is empty, the first -# character of the first item of `$expected'. Only the items from $expected, -# starting with this character are then expected as completions. -# @param list $expected List of all completions. -# @param string $cmd Command given to generate items -# @param string $partial Word to complete -# @param string $test Test title -# @param list $args See: assert_complete() -proc assert_complete_partial {expected cmd {partial ""} {test ""} {args {}}} { - if {$test == ""} {set test "$cmd should complete partial argument"} - if {[llength $expected] == 0} { - unresolved "$test" - } else { - set pick {} - # Make sure expected items are unique - set expected [lsort -unique $expected] - foreach item $expected { - if {$partial == ""} {set partial [string range $item 0 0]} - # Only append item if starting with $partial - if {[string range $item 0 [expr [string length $partial] - 1]] == "$partial"} { - lappend pick $item - } - } - # NOTE: The `eval' is necessary to flatten the $args list - # See also: http://wiki.tcl.tk/11787 - {expand} - eval assert_complete \$pick \"\$cmd \$partial\" \$test $args; #" - } -} - - # If cword contains colon (:), left-trim completions with cword # @param string $cmd Command to complete # @param list $items Reference to list of completions to trim @@ -781,7 +750,6 @@ proc _save_env {{file ""}} { # Source bash_completion package proc source_bash_completion {} { - assert_bash_exec {BASH_COMPLETION_COMPAT_DIR="$SRCDIR/fixtures/shared/empty_dir"} assert_bash_exec {source $(cd "$SRCDIR/.."; pwd)/bash_completion} } |