about summary refs log tree commit diff stats
diff options
context:
space:
mode:
-rw-r--r--.travis.yml11
-rwxr-xr-xtest_layers11
2 files changed, 17 insertions, 5 deletions
diff --git a/.travis.yml b/.travis.yml
index 6e617be0..e44f1f31 100644
--- a/.travis.yml
+++ b/.travis.yml
@@ -12,10 +12,17 @@ addons:
 before_install:
   - CXX=clang++
 
+# test_layers takes a long time; divide up the work into multiple jobs on the
+# matrix so we don't time out on Travis
 matrix:
   include:
-    - env: CXX=clang++ START=000 END=070
-    - env: CXX=clang++ START=070 END=999
+    - env: CXX=clang++ START=000 END=020
+    - env: CXX=clang++ START=020 END=040
+    - env: CXX=clang++ START=040 END=060
+    - env: CXX=clang++ START=060 END=070
+    - env: CXX=clang++ START=070 END=080
+    - env: CXX=clang++ START=080 END=090
+    - env: CXX=clang++ START=090 END=999
     - env: CXX=clang++ START=chessboard
     - env: CXX=clang++ START=edit
 
diff --git a/test_layers b/test_layers
index 81598241..88382a6e 100755
--- a/test_layers
+++ b/test_layers
@@ -1,4 +1,6 @@
 #!/bin/bash
+# Repeatedly stop building until successive layers, and run all tests built.
+#
 # Test all layers:
 #   test_layers
 # Test layers after x:
@@ -11,15 +13,18 @@
 for f in [0-9]*
 do
   if [[ $f < $1 ]]; then continue; fi
-  if [[ $2 && $f > $2 ]]; then continue; fi
+  if [[ $2 && $f > $2 ]]; then exit 0; fi
   echo "=== $f"
   ./build_and_test_until $f || exit 1
 done
 
+CXX=clang++ CFLAGS="-g -O3 -fsanitize=undefined -Wno-tautological-constant-out-of-range-compare" make
+VALGRIND="valgrind --leak-check=yes --num-callers=40 -q --error-exitcode=1"
+
 if [[ ! $1 || $1 == chessboard ]]
 then
   echo "=== chessboard"
-  ./mu test chessboard.mu || exit 1
+  $VALGRIND ./mu_bin test chessboard.mu || exit 1
 fi
 
 if [[ ! $1 || $1 == edit ]]
@@ -27,6 +32,6 @@ then
   for f in edit/[0-9]*
   do
     echo "=== edit: until $f"
-    ./mu test `echo edit/[0-9]* |perl -pwe "s,$f.*,$f,"` || exit 1
+    $VALGRIND ./mu_bin test `echo edit/[0-9]* |perl -pwe "s,$f.*,$f,"` || exit 1
   done
 fi