summaryrefslogtreecommitdiff
path: root/utils/bin/test_runner.sh
diff options
context:
space:
mode:
Diffstat (limited to 'utils/bin/test_runner.sh')
-rw-r--r--utils/bin/test_runner.sh9
1 files changed, 9 insertions, 0 deletions
diff --git a/utils/bin/test_runner.sh b/utils/bin/test_runner.sh
new file mode 100644
index 00000000..5b46e578
--- /dev/null
+++ b/utils/bin/test_runner.sh
@@ -0,0 +1,9 @@
+#!/usr/bin/env bash
+set -e
+
+# TODO: allow running with a minimal_init.lua
+if [ -n "$1" ]; then
+ nvim --headless -u ./init.lua -c "lua require('plenary.busted').run('$1')"
+else
+ nvim --headless -u ./init.lua -c "PlenaryBustedDirectory tests/ { minimal_init = './init.lua' }"
+fi