aboutsummaryrefslogtreecommitdiffhomepage
path: root/std/test_all.sh
diff options
context:
space:
mode:
Diffstat (limited to 'std/test_all.sh')
-rwxr-xr-xstd/test_all.sh16
1 files changed, 16 insertions, 0 deletions
diff --git a/std/test_all.sh b/std/test_all.sh
new file mode 100755
index 0000000..8b0740a
--- /dev/null
+++ b/std/test_all.sh
@@ -0,0 +1,16 @@
+#!/bin/sh
+
+echo "# useful for running all tests of the standard library" >All.bruijn
+echo >>All.bruijn
+
+FILES="$(find * -type f -name "*.bruijn" ! -name "All.bruijn")"
+
+for f in $FILES; do
+ echo ":import std/${f%*.bruijn} ." >>All.bruijn
+done
+
+# for ci, just run `bruijn All.bruijn`
+echo >>All.bruijn
+echo "main [[0]]" >>All.bruijn
+
+stack run -- All.bruijn | grep "ERROR" && exit 1 || exit 0