[MLton-commit] r6674

Wesley Terpstra wesley at mlton.org
Sun Jul 27 10:22:58 PDT 2008


Add a resume option to the regression testing tool
----------------------------------------------------------------------

U   mlton/trunk/bin/regression

----------------------------------------------------------------------

Modified: mlton/trunk/bin/regression
===================================================================
--- mlton/trunk/bin/regression	2008-07-26 23:50:01 UTC (rev 6673)
+++ mlton/trunk/bin/regression	2008-07-27 17:22:57 UTC (rev 6674)
@@ -8,12 +8,14 @@
 name=`basename "$0"`
 
 usage () {
-        echo >&2 "usage: $name [-cross target] [-run-only target] [-short] [-test-reg reg] [mlton flags ...]"
+        echo >&2 "usage: $name [-cross target] [-resume test] [-run-only target] [-short] [-test-reg reg] [mlton flags ...]"
         exit 1
 }
 
 cross='false'
 fail='false'
+resume='true'
+resumeTest='nil'
 runOnly='false'
 short='false'
 testReg='false'
@@ -37,6 +39,15 @@
                 fail='true'
                 shift
                 ;;
+        -resume)
+                resume='false'
+                shift
+                if [ "$#" = 0 ]; then
+                        usage
+                fi
+                resumeTest="$1"
+                shift
+                ;;
         -run-only)
                 runOnly='true'
                 shift
@@ -119,6 +130,13 @@
 
 for f in *.sml; do
         f=`basename "$f" .sml`
+ 	if ! ($resume); then
+                if [ "$f" == "$resumeTest" ]; then
+                        resume='true'
+                else
+                        continue
+                fi
+        fi
         if ($testReg); then
                 skip='true'
                 for (( i = 0 ; $i < ${#testRegs[@]} ; i++ )); do




More information about the MLton-commit mailing list