Reviewed tests p*
This commit is contained in:
parent
3d7321bc68
commit
53b1c41c16
@ -1 +0,0 @@
|
|||||||
source "lib/completions/p4.exp"
|
|
@ -1 +0,0 @@
|
|||||||
source "lib/completions/paste.exp"
|
|
@ -1 +0,0 @@
|
|||||||
source "lib/completions/patch.exp"
|
|
@ -1 +0,0 @@
|
|||||||
source "lib/completions/perl.exp"
|
|
@ -1 +0,0 @@
|
|||||||
source "lib/completions/perldoc.exp"
|
|
@ -1 +0,0 @@
|
|||||||
source "lib/completions/pine.exp"
|
|
@ -1 +0,0 @@
|
|||||||
source "lib/completions/pkg_deinstall.exp"
|
|
@ -1 +0,0 @@
|
|||||||
source "lib/completions/pkg_delete.exp"
|
|
@ -1 +0,0 @@
|
|||||||
source "lib/completions/pkg_info.exp"
|
|
@ -1 +0,0 @@
|
|||||||
source "lib/completions/portinstall.exp"
|
|
@ -1 +0,0 @@
|
|||||||
source "lib/completions/portupgrade.exp"
|
|
@ -1 +0,0 @@
|
|||||||
source "lib/completions/povray.exp"
|
|
@ -1 +0,0 @@
|
|||||||
source "lib/completions/pr.exp"
|
|
@ -1 +0,0 @@
|
|||||||
source "lib/completions/psql.exp"
|
|
@ -1 +0,0 @@
|
|||||||
source "lib/completions/ptx.exp"
|
|
@ -1 +0,0 @@
|
|||||||
source "lib/completions/python.exp"
|
|
3
test/completion/p4.exp
Normal file
3
test/completion/p4.exp
Normal file
@ -0,0 +1,3 @@
|
|||||||
|
if {[assert_bash_type p4]} {
|
||||||
|
source "lib/completions/p4.exp"
|
||||||
|
}; # if
|
3
test/completion/paste.exp
Normal file
3
test/completion/paste.exp
Normal file
@ -0,0 +1,3 @@
|
|||||||
|
if {[assert_bash_type paste]} {
|
||||||
|
source "lib/completions/paste.exp"
|
||||||
|
}; # if
|
3
test/completion/patch.exp
Normal file
3
test/completion/patch.exp
Normal file
@ -0,0 +1,3 @@
|
|||||||
|
if {[assert_bash_type patch]} {
|
||||||
|
source "lib/completions/patch.exp"
|
||||||
|
}; # if
|
3
test/completion/perl.exp
Normal file
3
test/completion/perl.exp
Normal file
@ -0,0 +1,3 @@
|
|||||||
|
if {[assert_bash_type {perl}]} {
|
||||||
|
source "lib/completions/perl.exp"
|
||||||
|
}; # if
|
3
test/completion/perldoc.exp
Normal file
3
test/completion/perldoc.exp
Normal file
@ -0,0 +1,3 @@
|
|||||||
|
if {[assert_bash_type perldoc]} {
|
||||||
|
source "lib/completions/perldoc.exp"
|
||||||
|
}; # if
|
3
test/completion/pine.exp
Normal file
3
test/completion/pine.exp
Normal file
@ -0,0 +1,3 @@
|
|||||||
|
if {[assert_bash_type pine]} {
|
||||||
|
source "lib/completions/pine.exp"
|
||||||
|
}; # if
|
3
test/completion/pkg_deinstall.exp
Normal file
3
test/completion/pkg_deinstall.exp
Normal file
@ -0,0 +1,3 @@
|
|||||||
|
if {[assert_bash_type pkg_deinstall]} {
|
||||||
|
source "lib/completions/pkg_deinstall.exp"
|
||||||
|
}; # if
|
3
test/completion/pkg_delete.exp
Normal file
3
test/completion/pkg_delete.exp
Normal file
@ -0,0 +1,3 @@
|
|||||||
|
if {[assert_bash_type pkg_delete]} {
|
||||||
|
source "lib/completions/pkg_delete.exp"
|
||||||
|
}; # if
|
3
test/completion/pkg_info.exp
Normal file
3
test/completion/pkg_info.exp
Normal file
@ -0,0 +1,3 @@
|
|||||||
|
if {[assert_bash_type pkg_info]} {
|
||||||
|
source "lib/completions/pkg_info.exp"
|
||||||
|
}; # if
|
3
test/completion/portinstall.exp
Normal file
3
test/completion/portinstall.exp
Normal file
@ -0,0 +1,3 @@
|
|||||||
|
if {[assert_bash_type portinstall]} {
|
||||||
|
source "lib/completions/portinstall.exp"
|
||||||
|
}; # if
|
3
test/completion/portupgrade.exp
Normal file
3
test/completion/portupgrade.exp
Normal file
@ -0,0 +1,3 @@
|
|||||||
|
if {[assert_bash_type portupgrade]} {
|
||||||
|
source "lib/completions/portupgrade.exp"
|
||||||
|
}; # if
|
3
test/completion/povray.exp
Normal file
3
test/completion/povray.exp
Normal file
@ -0,0 +1,3 @@
|
|||||||
|
if {[assert_bash_type povray]} {
|
||||||
|
source "lib/completions/povray.exp"
|
||||||
|
}; # if
|
3
test/completion/pr.exp
Normal file
3
test/completion/pr.exp
Normal file
@ -0,0 +1,3 @@
|
|||||||
|
if {[assert_bash_type pr]} {
|
||||||
|
source "lib/completions/pr.exp"
|
||||||
|
}; # if
|
3
test/completion/psql.exp
Normal file
3
test/completion/psql.exp
Normal file
@ -0,0 +1,3 @@
|
|||||||
|
if {[assert_bash_type psql]} {
|
||||||
|
source "lib/completions/psql.exp"
|
||||||
|
}; # if
|
3
test/completion/ptx.exp
Normal file
3
test/completion/ptx.exp
Normal file
@ -0,0 +1,3 @@
|
|||||||
|
if {[assert_bash_type ptx]} {
|
||||||
|
source "lib/completions/ptx.exp"
|
||||||
|
}; # if
|
3
test/completion/python.exp
Normal file
3
test/completion/python.exp
Normal file
@ -0,0 +1,3 @@
|
|||||||
|
if {[assert_bash_type python]} {
|
||||||
|
source "lib/completions/python.exp"
|
||||||
|
}; # if
|
20
test/lib/completions/p4.exp
Normal file
20
test/lib/completions/p4.exp
Normal file
@ -0,0 +1,20 @@
|
|||||||
|
proc setup {} {
|
||||||
|
save_env
|
||||||
|
}; # setup()
|
||||||
|
|
||||||
|
|
||||||
|
proc teardown {} {
|
||||||
|
assert_env_unmodified
|
||||||
|
}; # teardown()
|
||||||
|
|
||||||
|
|
||||||
|
setup
|
||||||
|
|
||||||
|
|
||||||
|
assert_complete_any "p4 "
|
||||||
|
|
||||||
|
|
||||||
|
sync_after_int
|
||||||
|
|
||||||
|
|
||||||
|
teardown
|
20
test/lib/completions/paste.exp
Normal file
20
test/lib/completions/paste.exp
Normal file
@ -0,0 +1,20 @@
|
|||||||
|
proc setup {} {
|
||||||
|
save_env
|
||||||
|
}; # setup()
|
||||||
|
|
||||||
|
|
||||||
|
proc teardown {} {
|
||||||
|
assert_env_unmodified
|
||||||
|
}; # teardown()
|
||||||
|
|
||||||
|
|
||||||
|
setup
|
||||||
|
|
||||||
|
|
||||||
|
assert_complete_any "paste "
|
||||||
|
|
||||||
|
|
||||||
|
sync_after_int
|
||||||
|
|
||||||
|
|
||||||
|
teardown
|
20
test/lib/completions/patch.exp
Normal file
20
test/lib/completions/patch.exp
Normal file
@ -0,0 +1,20 @@
|
|||||||
|
proc setup {} {
|
||||||
|
save_env
|
||||||
|
}; # setup()
|
||||||
|
|
||||||
|
|
||||||
|
proc teardown {} {
|
||||||
|
assert_env_unmodified
|
||||||
|
}; # teardown()
|
||||||
|
|
||||||
|
|
||||||
|
setup
|
||||||
|
|
||||||
|
|
||||||
|
assert_complete_any "patch "
|
||||||
|
|
||||||
|
|
||||||
|
sync_after_int
|
||||||
|
|
||||||
|
|
||||||
|
teardown
|
@ -1,23 +1,17 @@
|
|||||||
proc setup {} {
|
proc setup {} {
|
||||||
|
save_env
|
||||||
}; # setup()
|
}; # setup()
|
||||||
|
|
||||||
|
|
||||||
proc teardown {} {
|
proc teardown {} {
|
||||||
|
assert_env_unmodified
|
||||||
}; # teardown()
|
}; # teardown()
|
||||||
|
|
||||||
|
|
||||||
setup
|
setup
|
||||||
|
|
||||||
|
|
||||||
set test "Tab should show completions"
|
assert_complete_any "perl "
|
||||||
# Try completion
|
|
||||||
set cmd "perl "
|
|
||||||
send "$cmd\t"
|
|
||||||
expect {
|
|
||||||
-re "^$cmd\r\n.*\r\n/@$cmd$" { pass "$test" }
|
|
||||||
-re /@ { unresolved "$test at prompt" }
|
|
||||||
-re eof { unresolved "eof" }
|
|
||||||
}; # expect
|
|
||||||
|
|
||||||
|
|
||||||
sync_after_int
|
sync_after_int
|
||||||
@ -40,7 +34,7 @@ set test "-I without space should complete directories"
|
|||||||
set cmd "perl -Ifixture1/"
|
set cmd "perl -Ifixture1/"
|
||||||
send "$cmd\t"
|
send "$cmd\t"
|
||||||
expect {
|
expect {
|
||||||
-re "^$cmd\r\n(\.svn/ +|)bar bar.d/ +foo.d/ *(\.svn/ *|)\r\n/@$cmd$" { pass "$test" }
|
-re "^$cmd\r\nbar bar.d/ +foo.d/ *\r\n/@$cmd$" { pass "$test" }
|
||||||
-re /@ { unresolved "$test at prompt" }
|
-re /@ { unresolved "$test at prompt" }
|
||||||
-re eof { unresolved "eof" }
|
-re eof { unresolved "eof" }
|
||||||
}
|
}
|
||||||
@ -53,7 +47,7 @@ set test "-I with space should complete directories"
|
|||||||
set cmd "perl -I fixture1/"
|
set cmd "perl -I fixture1/"
|
||||||
send "$cmd\t"
|
send "$cmd\t"
|
||||||
expect {
|
expect {
|
||||||
-re "^$cmd\r\n(\.svn/ +|)bar bar.d/ +foo.d/ *(\.svn/ *|)\r\n/@$cmd$" { pass "$test" }
|
-re "^$cmd\r\nbar bar.d/ +foo.d/ *\r\n/@$cmd$" { pass "$test" }
|
||||||
-re /@ { unresolved "$test at prompt" }
|
-re /@ { unresolved "$test at prompt" }
|
||||||
-re eof { unresolved "eof" }
|
-re eof { unresolved "eof" }
|
||||||
}
|
}
|
||||||
@ -89,14 +83,10 @@ sync_after_int
|
|||||||
|
|
||||||
|
|
||||||
set test "- should complete options"
|
set test "- should complete options"
|
||||||
# Try completion
|
set options {
|
||||||
set cmd "perl -"
|
-0 -a -c -C -d -D -e -F -h -i -I -l -m -M -n -p -P -s -S -T -u -U -v -V -w -W -x -X
|
||||||
send "$cmd\t"
|
}
|
||||||
expect {
|
assert_complete $options "perl -"
|
||||||
-re "^$cmd\r\n-0 +-a +-c +-C +-d +-D +-e +-F +-h +-i +-I +-l +-m +-M +-n +-p +-P +-s +-S +-T +-u +-U +-v +-V +-w +-W +-x +-X\r\n/@$cmd$" { pass "$test" }
|
|
||||||
-re /@ { unresolved "$test at prompt" }
|
|
||||||
-re eof { unresolved "eof" }
|
|
||||||
}; # expect
|
|
||||||
|
|
||||||
|
|
||||||
sync_after_int
|
sync_after_int
|
20
test/lib/completions/perldoc.exp
Normal file
20
test/lib/completions/perldoc.exp
Normal file
@ -0,0 +1,20 @@
|
|||||||
|
proc setup {} {
|
||||||
|
save_env
|
||||||
|
}; # setup()
|
||||||
|
|
||||||
|
|
||||||
|
proc teardown {} {
|
||||||
|
assert_env_unmodified
|
||||||
|
}; # teardown()
|
||||||
|
|
||||||
|
|
||||||
|
setup
|
||||||
|
|
||||||
|
|
||||||
|
assert_complete_any "perldoc -"
|
||||||
|
|
||||||
|
|
||||||
|
sync_after_int
|
||||||
|
|
||||||
|
|
||||||
|
teardown
|
20
test/lib/completions/pine.exp
Normal file
20
test/lib/completions/pine.exp
Normal file
@ -0,0 +1,20 @@
|
|||||||
|
proc setup {} {
|
||||||
|
save_env
|
||||||
|
}; # setup()
|
||||||
|
|
||||||
|
|
||||||
|
proc teardown {} {
|
||||||
|
assert_env_unmodified
|
||||||
|
}; # teardown()
|
||||||
|
|
||||||
|
|
||||||
|
setup
|
||||||
|
|
||||||
|
|
||||||
|
assert_complete_any "pine "
|
||||||
|
|
||||||
|
|
||||||
|
sync_after_int
|
||||||
|
|
||||||
|
|
||||||
|
teardown
|
20
test/lib/completions/pkg-config.exp
Normal file
20
test/lib/completions/pkg-config.exp
Normal file
@ -0,0 +1,20 @@
|
|||||||
|
proc setup {} {
|
||||||
|
save_env
|
||||||
|
}; # setup()
|
||||||
|
|
||||||
|
|
||||||
|
proc teardown {} {
|
||||||
|
assert_env_unmodified
|
||||||
|
}; # teardown()
|
||||||
|
|
||||||
|
|
||||||
|
setup
|
||||||
|
|
||||||
|
|
||||||
|
assert_complete_any "pkg-config -"
|
||||||
|
|
||||||
|
|
||||||
|
sync_after_int
|
||||||
|
|
||||||
|
|
||||||
|
teardown
|
20
test/lib/completions/pkg_deinstall.exp
Normal file
20
test/lib/completions/pkg_deinstall.exp
Normal file
@ -0,0 +1,20 @@
|
|||||||
|
proc setup {} {
|
||||||
|
save_env
|
||||||
|
}; # setup()
|
||||||
|
|
||||||
|
|
||||||
|
proc teardown {} {
|
||||||
|
assert_env_unmodified
|
||||||
|
}; # teardown()
|
||||||
|
|
||||||
|
|
||||||
|
setup
|
||||||
|
|
||||||
|
|
||||||
|
assert_complete_any "pkg_deinstall "
|
||||||
|
|
||||||
|
|
||||||
|
sync_after_int
|
||||||
|
|
||||||
|
|
||||||
|
teardown
|
20
test/lib/completions/pkg_delete.exp
Normal file
20
test/lib/completions/pkg_delete.exp
Normal file
@ -0,0 +1,20 @@
|
|||||||
|
proc setup {} {
|
||||||
|
save_env
|
||||||
|
}; # setup()
|
||||||
|
|
||||||
|
|
||||||
|
proc teardown {} {
|
||||||
|
assert_env_unmodified
|
||||||
|
}; # teardown()
|
||||||
|
|
||||||
|
|
||||||
|
setup
|
||||||
|
|
||||||
|
|
||||||
|
assert_complete_any "pkg_delete "
|
||||||
|
|
||||||
|
|
||||||
|
sync_after_int
|
||||||
|
|
||||||
|
|
||||||
|
teardown
|
20
test/lib/completions/pkg_info.exp
Normal file
20
test/lib/completions/pkg_info.exp
Normal file
@ -0,0 +1,20 @@
|
|||||||
|
proc setup {} {
|
||||||
|
save_env
|
||||||
|
}; # setup()
|
||||||
|
|
||||||
|
|
||||||
|
proc teardown {} {
|
||||||
|
assert_env_unmodified
|
||||||
|
}; # teardown()
|
||||||
|
|
||||||
|
|
||||||
|
setup
|
||||||
|
|
||||||
|
|
||||||
|
assert_complete_any "pkg_info "
|
||||||
|
|
||||||
|
|
||||||
|
sync_after_int
|
||||||
|
|
||||||
|
|
||||||
|
teardown
|
20
test/lib/completions/portinstall.exp
Normal file
20
test/lib/completions/portinstall.exp
Normal file
@ -0,0 +1,20 @@
|
|||||||
|
proc setup {} {
|
||||||
|
save_env
|
||||||
|
}; # setup()
|
||||||
|
|
||||||
|
|
||||||
|
proc teardown {} {
|
||||||
|
assert_env_unmodified
|
||||||
|
}; # teardown()
|
||||||
|
|
||||||
|
|
||||||
|
setup
|
||||||
|
|
||||||
|
|
||||||
|
assert_complete_any "portinstall "
|
||||||
|
|
||||||
|
|
||||||
|
sync_after_int
|
||||||
|
|
||||||
|
|
||||||
|
teardown
|
20
test/lib/completions/portupgrade.exp
Normal file
20
test/lib/completions/portupgrade.exp
Normal file
@ -0,0 +1,20 @@
|
|||||||
|
proc setup {} {
|
||||||
|
save_env
|
||||||
|
}; # setup()
|
||||||
|
|
||||||
|
|
||||||
|
proc teardown {} {
|
||||||
|
assert_env_unmodified
|
||||||
|
}; # teardown()
|
||||||
|
|
||||||
|
|
||||||
|
setup
|
||||||
|
|
||||||
|
|
||||||
|
assert_complete_any "portupgrade "
|
||||||
|
|
||||||
|
|
||||||
|
sync_after_int
|
||||||
|
|
||||||
|
|
||||||
|
teardown
|
20
test/lib/completions/povray.exp
Normal file
20
test/lib/completions/povray.exp
Normal file
@ -0,0 +1,20 @@
|
|||||||
|
proc setup {} {
|
||||||
|
save_env
|
||||||
|
}; # setup()
|
||||||
|
|
||||||
|
|
||||||
|
proc teardown {} {
|
||||||
|
assert_env_unmodified
|
||||||
|
}; # teardown()
|
||||||
|
|
||||||
|
|
||||||
|
setup
|
||||||
|
|
||||||
|
|
||||||
|
assert_complete_any "povray "
|
||||||
|
|
||||||
|
|
||||||
|
sync_after_int
|
||||||
|
|
||||||
|
|
||||||
|
teardown
|
20
test/lib/completions/pr.exp
Normal file
20
test/lib/completions/pr.exp
Normal file
@ -0,0 +1,20 @@
|
|||||||
|
proc setup {} {
|
||||||
|
save_env
|
||||||
|
}; # setup()
|
||||||
|
|
||||||
|
|
||||||
|
proc teardown {} {
|
||||||
|
assert_env_unmodified
|
||||||
|
}; # teardown()
|
||||||
|
|
||||||
|
|
||||||
|
setup
|
||||||
|
|
||||||
|
|
||||||
|
assert_complete_any "pr "
|
||||||
|
|
||||||
|
|
||||||
|
sync_after_int
|
||||||
|
|
||||||
|
|
||||||
|
teardown
|
20
test/lib/completions/psql.exp
Normal file
20
test/lib/completions/psql.exp
Normal file
@ -0,0 +1,20 @@
|
|||||||
|
proc setup {} {
|
||||||
|
save_env
|
||||||
|
}; # setup()
|
||||||
|
|
||||||
|
|
||||||
|
proc teardown {} {
|
||||||
|
assert_env_unmodified
|
||||||
|
}; # teardown()
|
||||||
|
|
||||||
|
|
||||||
|
setup
|
||||||
|
|
||||||
|
|
||||||
|
assert_complete_any "psql -"
|
||||||
|
|
||||||
|
|
||||||
|
sync_after_int
|
||||||
|
|
||||||
|
|
||||||
|
teardown
|
20
test/lib/completions/ptx.exp
Normal file
20
test/lib/completions/ptx.exp
Normal file
@ -0,0 +1,20 @@
|
|||||||
|
proc setup {} {
|
||||||
|
save_env
|
||||||
|
}; # setup()
|
||||||
|
|
||||||
|
|
||||||
|
proc teardown {} {
|
||||||
|
assert_env_unmodified
|
||||||
|
}; # teardown()
|
||||||
|
|
||||||
|
|
||||||
|
setup
|
||||||
|
|
||||||
|
|
||||||
|
assert_complete_any "ptx "
|
||||||
|
|
||||||
|
|
||||||
|
sync_after_int
|
||||||
|
|
||||||
|
|
||||||
|
teardown
|
20
test/lib/completions/pvchange.exp
Normal file
20
test/lib/completions/pvchange.exp
Normal file
@ -0,0 +1,20 @@
|
|||||||
|
proc setup {} {
|
||||||
|
save_env
|
||||||
|
}; # setup()
|
||||||
|
|
||||||
|
|
||||||
|
proc teardown {} {
|
||||||
|
assert_env_unmodified
|
||||||
|
}; # teardown()
|
||||||
|
|
||||||
|
|
||||||
|
setup
|
||||||
|
|
||||||
|
|
||||||
|
assert_complete_any "pvchange --"
|
||||||
|
|
||||||
|
|
||||||
|
sync_after_int
|
||||||
|
|
||||||
|
|
||||||
|
teardown
|
20
test/lib/completions/pvcreate.exp
Normal file
20
test/lib/completions/pvcreate.exp
Normal file
@ -0,0 +1,20 @@
|
|||||||
|
proc setup {} {
|
||||||
|
save_env
|
||||||
|
}; # setup()
|
||||||
|
|
||||||
|
|
||||||
|
proc teardown {} {
|
||||||
|
assert_env_unmodified
|
||||||
|
}; # teardown()
|
||||||
|
|
||||||
|
|
||||||
|
setup
|
||||||
|
|
||||||
|
|
||||||
|
assert_complete_any "pvcreate --"
|
||||||
|
|
||||||
|
|
||||||
|
sync_after_int
|
||||||
|
|
||||||
|
|
||||||
|
teardown
|
20
test/lib/completions/pvdisplay.exp
Normal file
20
test/lib/completions/pvdisplay.exp
Normal file
@ -0,0 +1,20 @@
|
|||||||
|
proc setup {} {
|
||||||
|
save_env
|
||||||
|
}; # setup()
|
||||||
|
|
||||||
|
|
||||||
|
proc teardown {} {
|
||||||
|
assert_env_unmodified
|
||||||
|
}; # teardown()
|
||||||
|
|
||||||
|
|
||||||
|
setup
|
||||||
|
|
||||||
|
|
||||||
|
assert_complete_any "pvdisplay --"
|
||||||
|
|
||||||
|
|
||||||
|
sync_after_int
|
||||||
|
|
||||||
|
|
||||||
|
teardown
|
20
test/lib/completions/pvmove.exp
Normal file
20
test/lib/completions/pvmove.exp
Normal file
@ -0,0 +1,20 @@
|
|||||||
|
proc setup {} {
|
||||||
|
save_env
|
||||||
|
}; # setup()
|
||||||
|
|
||||||
|
|
||||||
|
proc teardown {} {
|
||||||
|
assert_env_unmodified
|
||||||
|
}; # teardown()
|
||||||
|
|
||||||
|
|
||||||
|
setup
|
||||||
|
|
||||||
|
|
||||||
|
assert_complete_any "pvmove --"
|
||||||
|
|
||||||
|
|
||||||
|
sync_after_int
|
||||||
|
|
||||||
|
|
||||||
|
teardown
|
20
test/lib/completions/pvremove.exp
Normal file
20
test/lib/completions/pvremove.exp
Normal file
@ -0,0 +1,20 @@
|
|||||||
|
proc setup {} {
|
||||||
|
save_env
|
||||||
|
}; # setup()
|
||||||
|
|
||||||
|
|
||||||
|
proc teardown {} {
|
||||||
|
assert_env_unmodified
|
||||||
|
}; # teardown()
|
||||||
|
|
||||||
|
|
||||||
|
setup
|
||||||
|
|
||||||
|
|
||||||
|
assert_complete_any "pvremove --"
|
||||||
|
|
||||||
|
|
||||||
|
sync_after_int
|
||||||
|
|
||||||
|
|
||||||
|
teardown
|
20
test/lib/completions/pvs.exp
Normal file
20
test/lib/completions/pvs.exp
Normal file
@ -0,0 +1,20 @@
|
|||||||
|
proc setup {} {
|
||||||
|
save_env
|
||||||
|
}; # setup()
|
||||||
|
|
||||||
|
|
||||||
|
proc teardown {} {
|
||||||
|
assert_env_unmodified
|
||||||
|
}; # teardown()
|
||||||
|
|
||||||
|
|
||||||
|
setup
|
||||||
|
|
||||||
|
|
||||||
|
assert_complete_any "pvs --"
|
||||||
|
|
||||||
|
|
||||||
|
sync_after_int
|
||||||
|
|
||||||
|
|
||||||
|
teardown
|
20
test/lib/completions/pvscan.exp
Normal file
20
test/lib/completions/pvscan.exp
Normal file
@ -0,0 +1,20 @@
|
|||||||
|
proc setup {} {
|
||||||
|
save_env
|
||||||
|
}; # setup()
|
||||||
|
|
||||||
|
|
||||||
|
proc teardown {} {
|
||||||
|
assert_env_unmodified
|
||||||
|
}; # teardown()
|
||||||
|
|
||||||
|
|
||||||
|
setup
|
||||||
|
|
||||||
|
|
||||||
|
assert_complete_any "pvscan --"
|
||||||
|
|
||||||
|
|
||||||
|
sync_after_int
|
||||||
|
|
||||||
|
|
||||||
|
teardown
|
20
test/lib/completions/python.exp
Normal file
20
test/lib/completions/python.exp
Normal file
@ -0,0 +1,20 @@
|
|||||||
|
proc setup {} {
|
||||||
|
save_env
|
||||||
|
}; # setup()
|
||||||
|
|
||||||
|
|
||||||
|
proc teardown {} {
|
||||||
|
assert_env_unmodified
|
||||||
|
}; # teardown()
|
||||||
|
|
||||||
|
|
||||||
|
setup
|
||||||
|
|
||||||
|
|
||||||
|
assert_complete_any "python "
|
||||||
|
|
||||||
|
|
||||||
|
sync_after_int
|
||||||
|
|
||||||
|
|
||||||
|
teardown
|
@ -1,26 +0,0 @@
|
|||||||
proc setup {} {
|
|
||||||
}; # setup()
|
|
||||||
|
|
||||||
|
|
||||||
proc teardown {} {
|
|
||||||
}; # teardown()
|
|
||||||
|
|
||||||
|
|
||||||
setup
|
|
||||||
|
|
||||||
|
|
||||||
set test "Tab should complete"
|
|
||||||
# Try completion
|
|
||||||
set cmd "p4 "
|
|
||||||
send "$cmd\t"
|
|
||||||
expect {
|
|
||||||
-re "^${cmd}(bash: p4: command not found|)\r\n.*$cmd$" { pass "$test" }
|
|
||||||
-re /@ { unresolved "$test at prompt" }
|
|
||||||
-re eof { unresolved "eof" }
|
|
||||||
}; # expect
|
|
||||||
|
|
||||||
|
|
||||||
sync_after_int
|
|
||||||
|
|
||||||
|
|
||||||
teardown
|
|
@ -1,26 +0,0 @@
|
|||||||
proc setup {} {
|
|
||||||
}; # setup()
|
|
||||||
|
|
||||||
|
|
||||||
proc teardown {} {
|
|
||||||
}; # teardown()
|
|
||||||
|
|
||||||
|
|
||||||
setup
|
|
||||||
|
|
||||||
|
|
||||||
set test "Tab should complete"
|
|
||||||
# Try completion
|
|
||||||
set cmd "paste "
|
|
||||||
send "$cmd\t"
|
|
||||||
expect {
|
|
||||||
-re "^$cmd\r\n.*$cmd$" { pass "$test" }
|
|
||||||
-re /@ { unresolved "$test at prompt" }
|
|
||||||
-re eof { unresolved "eof" }
|
|
||||||
}; # expect
|
|
||||||
|
|
||||||
|
|
||||||
sync_after_int
|
|
||||||
|
|
||||||
|
|
||||||
teardown
|
|
@ -1,26 +0,0 @@
|
|||||||
proc setup {} {
|
|
||||||
}; # setup()
|
|
||||||
|
|
||||||
|
|
||||||
proc teardown {} {
|
|
||||||
}; # teardown()
|
|
||||||
|
|
||||||
|
|
||||||
setup
|
|
||||||
|
|
||||||
|
|
||||||
set test "Tab should complete"
|
|
||||||
# Try completion
|
|
||||||
set cmd "patch "
|
|
||||||
send "$cmd\t"
|
|
||||||
expect {
|
|
||||||
-re "^$cmd\r\n.*$cmd$" { pass "$test" }
|
|
||||||
-re /@ { unresolved "$test at prompt" }
|
|
||||||
-re eof { unresolved "eof" }
|
|
||||||
}; # expect
|
|
||||||
|
|
||||||
|
|
||||||
sync_after_int
|
|
||||||
|
|
||||||
|
|
||||||
teardown
|
|
@ -1,26 +0,0 @@
|
|||||||
proc setup {} {
|
|
||||||
}; # setup()
|
|
||||||
|
|
||||||
|
|
||||||
proc teardown {} {
|
|
||||||
}; # teardown()
|
|
||||||
|
|
||||||
|
|
||||||
setup
|
|
||||||
|
|
||||||
|
|
||||||
set test "Tab should complete"
|
|
||||||
# Try completion
|
|
||||||
set cmd "perldoc -"
|
|
||||||
send "$cmd\t"
|
|
||||||
expect {
|
|
||||||
-re "^$cmd\r\n.*$cmd$" { pass "$test" }
|
|
||||||
-re /@ { unresolved "$test at prompt" }
|
|
||||||
-re eof { unresolved "eof" }
|
|
||||||
}; # expect
|
|
||||||
|
|
||||||
|
|
||||||
sync_after_int
|
|
||||||
|
|
||||||
|
|
||||||
teardown
|
|
@ -1,26 +0,0 @@
|
|||||||
proc setup {} {
|
|
||||||
}; # setup()
|
|
||||||
|
|
||||||
|
|
||||||
proc teardown {} {
|
|
||||||
}; # teardown()
|
|
||||||
|
|
||||||
|
|
||||||
setup
|
|
||||||
|
|
||||||
|
|
||||||
set test "Tab should complete"
|
|
||||||
# Try completion
|
|
||||||
set cmd "pine "
|
|
||||||
send "$cmd\t"
|
|
||||||
expect {
|
|
||||||
-re "^$cmd\r\n.*$cmd$" { pass "$test" }
|
|
||||||
-re /@ { unresolved "$test at prompt" }
|
|
||||||
-re eof { unresolved "eof" }
|
|
||||||
}; # expect
|
|
||||||
|
|
||||||
|
|
||||||
sync_after_int
|
|
||||||
|
|
||||||
|
|
||||||
teardown
|
|
@ -1,26 +0,0 @@
|
|||||||
proc setup {} {
|
|
||||||
}; # setup()
|
|
||||||
|
|
||||||
|
|
||||||
proc teardown {} {
|
|
||||||
}; # teardown()
|
|
||||||
|
|
||||||
|
|
||||||
setup
|
|
||||||
|
|
||||||
|
|
||||||
set test "Tab should complete"
|
|
||||||
# Try completion
|
|
||||||
set cmd "pkg-config -"
|
|
||||||
send "$cmd\t"
|
|
||||||
expect {
|
|
||||||
-re "^$cmd\r\n.*$cmd$" { pass "$test" }
|
|
||||||
-re /@ { unresolved "$test at prompt" }
|
|
||||||
-re eof { unresolved "eof" }
|
|
||||||
}; # expect
|
|
||||||
|
|
||||||
|
|
||||||
sync_after_int
|
|
||||||
|
|
||||||
|
|
||||||
teardown
|
|
@ -1,26 +0,0 @@
|
|||||||
proc setup {} {
|
|
||||||
}; # setup()
|
|
||||||
|
|
||||||
|
|
||||||
proc teardown {} {
|
|
||||||
}; # teardown()
|
|
||||||
|
|
||||||
|
|
||||||
setup
|
|
||||||
|
|
||||||
|
|
||||||
set test "Tab should complete"
|
|
||||||
# Try completion
|
|
||||||
set cmd "pkg_deinstall "
|
|
||||||
send "$cmd\t"
|
|
||||||
expect {
|
|
||||||
-re "^$cmd\r\n.*$cmd$" { pass "$test" }
|
|
||||||
-re /@ { unresolved "$test at prompt" }
|
|
||||||
-re eof { unresolved "eof" }
|
|
||||||
}; # expect
|
|
||||||
|
|
||||||
|
|
||||||
sync_after_int
|
|
||||||
|
|
||||||
|
|
||||||
teardown
|
|
@ -1,26 +0,0 @@
|
|||||||
proc setup {} {
|
|
||||||
}; # setup()
|
|
||||||
|
|
||||||
|
|
||||||
proc teardown {} {
|
|
||||||
}; # teardown()
|
|
||||||
|
|
||||||
|
|
||||||
setup
|
|
||||||
|
|
||||||
|
|
||||||
set test "Tab should complete"
|
|
||||||
# Try completion
|
|
||||||
set cmd "pkg_delete "
|
|
||||||
send "$cmd\t"
|
|
||||||
expect {
|
|
||||||
-re "^$cmd\r\n.*$cmd$" { pass "$test" }
|
|
||||||
-re /@ { unresolved "$test at prompt" }
|
|
||||||
-re eof { unresolved "eof" }
|
|
||||||
}; # expect
|
|
||||||
|
|
||||||
|
|
||||||
sync_after_int
|
|
||||||
|
|
||||||
|
|
||||||
teardown
|
|
@ -1,26 +0,0 @@
|
|||||||
proc setup {} {
|
|
||||||
}; # setup()
|
|
||||||
|
|
||||||
|
|
||||||
proc teardown {} {
|
|
||||||
}; # teardown()
|
|
||||||
|
|
||||||
|
|
||||||
setup
|
|
||||||
|
|
||||||
|
|
||||||
set test "Tab should complete"
|
|
||||||
# Try completion
|
|
||||||
set cmd "pkg_info "
|
|
||||||
send "$cmd\t"
|
|
||||||
expect {
|
|
||||||
-re "^$cmd\r\n.*$cmd$" { pass "$test" }
|
|
||||||
-re /@ { unresolved "$test at prompt" }
|
|
||||||
-re eof { unresolved "eof" }
|
|
||||||
}; # expect
|
|
||||||
|
|
||||||
|
|
||||||
sync_after_int
|
|
||||||
|
|
||||||
|
|
||||||
teardown
|
|
@ -1,26 +0,0 @@
|
|||||||
proc setup {} {
|
|
||||||
}; # setup()
|
|
||||||
|
|
||||||
|
|
||||||
proc teardown {} {
|
|
||||||
}; # teardown()
|
|
||||||
|
|
||||||
|
|
||||||
setup
|
|
||||||
|
|
||||||
|
|
||||||
set test "Tab should complete"
|
|
||||||
# Try completion
|
|
||||||
set cmd "portinstall "
|
|
||||||
send "$cmd\t"
|
|
||||||
expect {
|
|
||||||
-re "^${cmd}(bash: /usr/ports//INDEX: No such file or directory\r\n)*\r\n.*$cmd$" { pass "$test" }
|
|
||||||
-re /@ { unresolved "$test at prompt" }
|
|
||||||
-re eof { unresolved "eof" }
|
|
||||||
}; # expect
|
|
||||||
|
|
||||||
|
|
||||||
sync_after_int
|
|
||||||
|
|
||||||
|
|
||||||
teardown
|
|
@ -1,26 +0,0 @@
|
|||||||
proc setup {} {
|
|
||||||
}; # setup()
|
|
||||||
|
|
||||||
|
|
||||||
proc teardown {} {
|
|
||||||
}; # teardown()
|
|
||||||
|
|
||||||
|
|
||||||
setup
|
|
||||||
|
|
||||||
|
|
||||||
set test "Tab should complete"
|
|
||||||
# Try completion
|
|
||||||
set cmd "portupgrade "
|
|
||||||
send "$cmd\t"
|
|
||||||
expect {
|
|
||||||
-re "^$cmd\r\n.*$cmd$" { pass "$test" }
|
|
||||||
-re /@ { unresolved "$test at prompt" }
|
|
||||||
-re eof { unresolved "eof" }
|
|
||||||
}; # expect
|
|
||||||
|
|
||||||
|
|
||||||
sync_after_int
|
|
||||||
|
|
||||||
|
|
||||||
teardown
|
|
@ -1,26 +0,0 @@
|
|||||||
proc setup {} {
|
|
||||||
}; # setup()
|
|
||||||
|
|
||||||
|
|
||||||
proc teardown {} {
|
|
||||||
}; # teardown()
|
|
||||||
|
|
||||||
|
|
||||||
setup
|
|
||||||
|
|
||||||
|
|
||||||
set test "Tab should complete"
|
|
||||||
# Try completion
|
|
||||||
set cmd "povray "
|
|
||||||
send "$cmd\t"
|
|
||||||
expect {
|
|
||||||
-re "^$cmd\r\n.*$cmd$" { pass "$test" }
|
|
||||||
-re /@ { unresolved "$test at prompt" }
|
|
||||||
-re eof { unresolved "eof" }
|
|
||||||
}; # expect
|
|
||||||
|
|
||||||
|
|
||||||
sync_after_int
|
|
||||||
|
|
||||||
|
|
||||||
teardown
|
|
@ -1,26 +0,0 @@
|
|||||||
proc setup {} {
|
|
||||||
}; # setup()
|
|
||||||
|
|
||||||
|
|
||||||
proc teardown {} {
|
|
||||||
}; # teardown()
|
|
||||||
|
|
||||||
|
|
||||||
setup
|
|
||||||
|
|
||||||
|
|
||||||
set test "Tab should complete"
|
|
||||||
# Try completion
|
|
||||||
set cmd "pr "
|
|
||||||
send "$cmd\t"
|
|
||||||
expect {
|
|
||||||
-re "^$cmd\r\n.*$cmd$" { pass "$test" }
|
|
||||||
-re /@ { unresolved "$test at prompt" }
|
|
||||||
-re eof { unresolved "eof" }
|
|
||||||
}; # expect
|
|
||||||
|
|
||||||
|
|
||||||
sync_after_int
|
|
||||||
|
|
||||||
|
|
||||||
teardown
|
|
@ -1,26 +0,0 @@
|
|||||||
proc setup {} {
|
|
||||||
}; # setup()
|
|
||||||
|
|
||||||
|
|
||||||
proc teardown {} {
|
|
||||||
}; # teardown()
|
|
||||||
|
|
||||||
|
|
||||||
setup
|
|
||||||
|
|
||||||
|
|
||||||
set test "Tab should complete"
|
|
||||||
# Try completion
|
|
||||||
set cmd "psql "
|
|
||||||
send "$cmd\t"
|
|
||||||
expect {
|
|
||||||
-re "^$cmd\r\n.*$cmd$" { pass "$test" }
|
|
||||||
-re /@ { unresolved "$test at prompt" }
|
|
||||||
-re eof { unresolved "eof" }
|
|
||||||
}; # expect
|
|
||||||
|
|
||||||
|
|
||||||
sync_after_int
|
|
||||||
|
|
||||||
|
|
||||||
teardown
|
|
@ -1,26 +0,0 @@
|
|||||||
proc setup {} {
|
|
||||||
}; # setup()
|
|
||||||
|
|
||||||
|
|
||||||
proc teardown {} {
|
|
||||||
}; # teardown()
|
|
||||||
|
|
||||||
|
|
||||||
setup
|
|
||||||
|
|
||||||
|
|
||||||
set test "Tab should complete"
|
|
||||||
# Try completion
|
|
||||||
set cmd "ptx "
|
|
||||||
send "$cmd\t"
|
|
||||||
expect {
|
|
||||||
-re "^$cmd\r\n.*$cmd$" { pass "$test" }
|
|
||||||
-re /@ { unresolved "$test at prompt" }
|
|
||||||
-re eof { unresolved "eof" }
|
|
||||||
}; # expect
|
|
||||||
|
|
||||||
|
|
||||||
sync_after_int
|
|
||||||
|
|
||||||
|
|
||||||
teardown
|
|
@ -1,26 +0,0 @@
|
|||||||
proc setup {} {
|
|
||||||
}; # setup()
|
|
||||||
|
|
||||||
|
|
||||||
proc teardown {} {
|
|
||||||
}; # teardown()
|
|
||||||
|
|
||||||
|
|
||||||
setup
|
|
||||||
|
|
||||||
|
|
||||||
set test "Tab should complete"
|
|
||||||
# Try completion
|
|
||||||
set cmd "pvchange --"
|
|
||||||
send "$cmd\t"
|
|
||||||
expect {
|
|
||||||
-re "^$cmd\r\n.*$cmd$" { pass "$test" }
|
|
||||||
-re /@ { unresolved "$test at prompt" }
|
|
||||||
-re eof { unresolved "eof" }
|
|
||||||
}; # expect
|
|
||||||
|
|
||||||
|
|
||||||
sync_after_int
|
|
||||||
|
|
||||||
|
|
||||||
teardown
|
|
@ -1,26 +0,0 @@
|
|||||||
proc setup {} {
|
|
||||||
}; # setup()
|
|
||||||
|
|
||||||
|
|
||||||
proc teardown {} {
|
|
||||||
}; # teardown()
|
|
||||||
|
|
||||||
|
|
||||||
setup
|
|
||||||
|
|
||||||
|
|
||||||
set test "Tab should complete"
|
|
||||||
# Try completion
|
|
||||||
set cmd "pvcreate --"
|
|
||||||
send "$cmd\t"
|
|
||||||
expect {
|
|
||||||
-re "^$cmd\r\n.*$cmd$" { pass "$test" }
|
|
||||||
-re /@ { unresolved "$test at prompt" }
|
|
||||||
-re eof { unresolved "eof" }
|
|
||||||
}; # expect
|
|
||||||
|
|
||||||
|
|
||||||
sync_after_int
|
|
||||||
|
|
||||||
|
|
||||||
teardown
|
|
@ -1,26 +0,0 @@
|
|||||||
proc setup {} {
|
|
||||||
}; # setup()
|
|
||||||
|
|
||||||
|
|
||||||
proc teardown {} {
|
|
||||||
}; # teardown()
|
|
||||||
|
|
||||||
|
|
||||||
setup
|
|
||||||
|
|
||||||
|
|
||||||
set test "Tab should complete"
|
|
||||||
# Try completion
|
|
||||||
set cmd "pvdisplay --"
|
|
||||||
send "$cmd\t"
|
|
||||||
expect {
|
|
||||||
-re "^$cmd\r\n.*$cmd$" { pass "$test" }
|
|
||||||
-re /@ { unresolved "$test at prompt" }
|
|
||||||
-re eof { unresolved "eof" }
|
|
||||||
}; # expect
|
|
||||||
|
|
||||||
|
|
||||||
sync_after_int
|
|
||||||
|
|
||||||
|
|
||||||
teardown
|
|
@ -1,26 +0,0 @@
|
|||||||
proc setup {} {
|
|
||||||
}; # setup()
|
|
||||||
|
|
||||||
|
|
||||||
proc teardown {} {
|
|
||||||
}; # teardown()
|
|
||||||
|
|
||||||
|
|
||||||
setup
|
|
||||||
|
|
||||||
|
|
||||||
set test "Tab should complete"
|
|
||||||
# Try completion
|
|
||||||
set cmd "pvmove --"
|
|
||||||
send "$cmd\t"
|
|
||||||
expect {
|
|
||||||
-re "^$cmd\r\n.*$cmd$" { pass "$test" }
|
|
||||||
-re /@ { unresolved "$test at prompt" }
|
|
||||||
-re eof { unresolved "eof" }
|
|
||||||
}; # expect
|
|
||||||
|
|
||||||
|
|
||||||
sync_after_int
|
|
||||||
|
|
||||||
|
|
||||||
teardown
|
|
@ -1,26 +0,0 @@
|
|||||||
proc setup {} {
|
|
||||||
}; # setup()
|
|
||||||
|
|
||||||
|
|
||||||
proc teardown {} {
|
|
||||||
}; # teardown()
|
|
||||||
|
|
||||||
|
|
||||||
setup
|
|
||||||
|
|
||||||
|
|
||||||
set test "Tab should complete"
|
|
||||||
# Try completion
|
|
||||||
set cmd "pvremove --"
|
|
||||||
send "$cmd\t"
|
|
||||||
expect {
|
|
||||||
-re "^$cmd\r\n.*$cmd$" { pass "$test" }
|
|
||||||
-re /@ { unresolved "$test at prompt" }
|
|
||||||
-re eof { unresolved "eof" }
|
|
||||||
}; # expect
|
|
||||||
|
|
||||||
|
|
||||||
sync_after_int
|
|
||||||
|
|
||||||
|
|
||||||
teardown
|
|
@ -1,26 +0,0 @@
|
|||||||
proc setup {} {
|
|
||||||
}; # setup()
|
|
||||||
|
|
||||||
|
|
||||||
proc teardown {} {
|
|
||||||
}; # teardown()
|
|
||||||
|
|
||||||
|
|
||||||
setup
|
|
||||||
|
|
||||||
|
|
||||||
set test "Tab should complete"
|
|
||||||
# Try completion
|
|
||||||
set cmd "pvs --"
|
|
||||||
send "$cmd\t"
|
|
||||||
expect {
|
|
||||||
-re "^$cmd\r\n.*$cmd$" { pass "$test" }
|
|
||||||
-re /@ { unresolved "$test at prompt" }
|
|
||||||
-re eof { unresolved "eof" }
|
|
||||||
}; # expect
|
|
||||||
|
|
||||||
|
|
||||||
sync_after_int
|
|
||||||
|
|
||||||
|
|
||||||
teardown
|
|
@ -1,26 +0,0 @@
|
|||||||
proc setup {} {
|
|
||||||
}; # setup()
|
|
||||||
|
|
||||||
|
|
||||||
proc teardown {} {
|
|
||||||
}; # teardown()
|
|
||||||
|
|
||||||
|
|
||||||
setup
|
|
||||||
|
|
||||||
|
|
||||||
set test "Tab should complete"
|
|
||||||
# Try completion
|
|
||||||
set cmd "pvscan --"
|
|
||||||
send "$cmd\t"
|
|
||||||
expect {
|
|
||||||
-re "^$cmd\r\n.*$cmd$" { pass "$test" }
|
|
||||||
-re /@ { unresolved "$test at prompt" }
|
|
||||||
-re eof { unresolved "eof" }
|
|
||||||
}; # expect
|
|
||||||
|
|
||||||
|
|
||||||
sync_after_int
|
|
||||||
|
|
||||||
|
|
||||||
teardown
|
|
@ -1,26 +0,0 @@
|
|||||||
proc setup {} {
|
|
||||||
}; # setup()
|
|
||||||
|
|
||||||
|
|
||||||
proc teardown {} {
|
|
||||||
}; # teardown()
|
|
||||||
|
|
||||||
|
|
||||||
setup
|
|
||||||
|
|
||||||
|
|
||||||
set test "Tab should complete"
|
|
||||||
# Try completion
|
|
||||||
set cmd "python "
|
|
||||||
send "$cmd\t"
|
|
||||||
expect {
|
|
||||||
-re "^$cmd\r\n.*$cmd$" { pass "$test" }
|
|
||||||
-re /@ { unresolved "$test at prompt" }
|
|
||||||
-re eof { unresolved "eof" }
|
|
||||||
}; # expect
|
|
||||||
|
|
||||||
|
|
||||||
sync_after_int
|
|
||||||
|
|
||||||
|
|
||||||
teardown
|
|
Loading…
x
Reference in New Issue
Block a user