summaryrefslogtreecommitdiff
path: root/test/lib/completions/man.exp
diff options
context:
space:
mode:
Diffstat (limited to 'test/lib/completions/man.exp')
-rw-r--r--test/lib/completions/man.exp76
1 files changed, 0 insertions, 76 deletions
diff --git a/test/lib/completions/man.exp b/test/lib/completions/man.exp
deleted file mode 100644
index d601c434..00000000
--- a/test/lib/completions/man.exp
+++ /dev/null
@@ -1,76 +0,0 @@
-proc setup {} {
- assert_bash_exec "export MANPATH=$::srcdirabs/fixtures/man:$::srcdirabs/tmp/man"
- save_env
-
- if {! [is_cygwin]} { # Colon not allowed in filenames
- assert_bash_exec {(cd $TESTDIR/tmp && mkdir -p man/man3 && touch man/man3/Bash::Completion.3pm.gz || true)}
- }
-}
-
-
-proc teardown {} {
- assert_env_unmodified {
- /OLDPWD/d
- /OLDMANPATH/d
- }
-
- if {! [is_cygwin]} {
- assert_bash_exec {(cd $TESTDIR/tmp && rm -r man || true)}
- }
-}
-
-
-setup
-
-
-# Something we assume a system installed man page present for
-set assumed_present "man"
-
-assert_complete "bash-completion-testcase" "man bash-completion-testcas"
-sync_after_int
-
-assert_complete_dir oo.1 "man man1/f" $::srcdir/fixtures/man
-sync_after_int
-
-if {! [is_cygwin]} {
- assert_complete "Bash::Completion" "man Bash::C"
- sync_after_int
-}
-
-assert_complete_dir "man/quux.8" "man man/" $::srcdir/fixtures/man
-sync_after_int
-
-set desc "man $assumed_present with MANPATH having no leading/trailing colon"
-assert_no_complete "man $assumed_present" "$desc should not complete"
-sync_after_int
-
-# Trailing colon in MANPATH: append system default search path
-assert_bash_exec "OLDMANPATH=\$MANPATH; MANPATH=\$MANPATH:"
-set desc "with trailing colon in MANPATH"
-
-set cmd "man $assumed_present"
-assert_complete_any "$cmd" "$cmd $desc should complete"
-sync_after_int
-
-set cmd "man bash-completion-testcas"
-assert_complete "bash-completion-testcase" "$cmd" "$cmd $desc should complete"
-sync_after_int
-
-assert_bash_exec "MANPATH=\$OLDMANPATH"
-
-# Leading colon in MANPATH: prepend system default search path
-assert_bash_exec "OLDMANPATH=\$MANPATH; MANPATH=:\$MANPATH"
-set desc "with leading colon in MANPATH"
-
-set cmd "man $assumed_present"
-assert_complete_any "$cmd" "$cmd $desc should complete"
-sync_after_int
-
-set cmd "man bash-completion-testcas"
-assert_complete "bash-completion-testcase" "$cmd" "$cmd $desc should complete"
-sync_after_int
-
-assert_bash_exec "MANPATH=\$OLDMANPATH"
-
-
-teardown