aboutsummaryrefslogtreecommitdiffhomepage
path: root/tests/interactive.fish
diff options
context:
space:
mode:
Diffstat (limited to 'tests/interactive.fish')
-rwxr-xr-x[-rw-r--r--]tests/interactive.fish14
1 files changed, 12 insertions, 2 deletions
diff --git a/tests/interactive.fish b/tests/interactive.fish
index ad53e262..9f5e979c 100644..100755
--- a/tests/interactive.fish
+++ b/tests/interactive.fish
@@ -2,7 +2,17 @@
#
# Interactive tests using `expect`
-source test_util.fish (status -f); or exit
+# Change to directory containing this script
+cd (dirname (status -f))
+
+# Test files specified on commandline, or all *.expect files
+if set -q argv[1]
+ set files_to_test $argv.expect
+else
+ set files_to_test *.expect
+end
+
+source test_util.fish (status -f) $argv; or exit
say -o cyan "Testing interactive functionality"
if not type -q expect
@@ -65,7 +75,7 @@ function test_file
end
set -l failed
-for i in *.expect
+for i in $files_to_test
if not test_file $i
set failed $failed $i
end