summaryrefslogtreecommitdiff
path: root/test/lib/completions/cvs.exp
diff options
context:
space:
mode:
Diffstat (limited to 'test/lib/completions/cvs.exp')
-rw-r--r--test/lib/completions/cvs.exp36
1 files changed, 36 insertions, 0 deletions
diff --git a/test/lib/completions/cvs.exp b/test/lib/completions/cvs.exp
new file mode 100644
index 00000000..2a26da8e
--- /dev/null
+++ b/test/lib/completions/cvs.exp
@@ -0,0 +1,36 @@
+proc setup {} {
+ save_env
+ assert_bash_exec {OLDHOME=$HOME ; HOME=$TESTDIR/fixtures/cvs}
+}; # setup()
+
+
+proc teardown {} {
+ assert_bash_exec {HOME=$OLDHOME}
+ assert_env_unmodified {
+ /OLDHOME=/d
+ }
+}; # teardown()
+
+
+setup
+
+
+assert_complete_any "cvs "
+
+
+sync_after_int
+
+
+set test "-d should complete CVS roots"
+set cmd "cvs -d "
+send "$cmd\t"
+expect {
+ -re "^$cmd\r\n.*:pserver:.*\r\n/@$cmd:pserver:.*$" { pass "$test" }
+ default { fail "$test" }
+}; # expect
+
+
+sync_after_int
+
+
+teardown