diff options
author | Ian Hinder <ian.hinder@aei.mpg.de> | 2013-09-05 20:32:18 +0200 |
---|---|---|
committer | Ian Hinder <ian.hinder@aei.mpg.de> | 2013-09-05 20:32:18 +0200 |
commit | 449186b46ac5884056acd072978b3fc500575a23 (patch) | |
tree | dfdd14d42a9e6453b7900e96e65251aad32d76ff /Tests | |
parent | 8aaf3ebab720eadd5bfda1dd3beef6c6ec2ae2f9 (diff) |
RunTests.m: Allow selection of test suite file to run
Cannot run individual tests yet
Diffstat (limited to 'Tests')
-rwxr-xr-x | Tests/RunTests.m | 13 |
1 files changed, 10 insertions, 3 deletions
diff --git a/Tests/RunTests.m b/Tests/RunTests.m index 5d749ac..d54c480 100755 --- a/Tests/RunTests.m +++ b/Tests/RunTests.m @@ -1,4 +1,4 @@ -#!/usr/bin/env math -script +#!/usr/bin/env MathematicaScript -script SetOptions[ $Output, FormatType -> OutputForm ]; @@ -18,12 +18,19 @@ Needs["Errors`"]; Needs["KrancThorn`"]; (* (\* Needs["Profile`"]; *\) *) -SetDebugLevel[DebugQuiet]; +(* SetDebugLevel[DebugQuiet]; *) -tests = { +alltests = { "Kranc", "McLachlan" }; +args = Drop[$ScriptCommandLine, 1]; + +If[Length[args] > 0, + If[StringMatchQ[args[[1]], "*.mt"], + tests = {StringReplace[args[[1]], ".mt" -> ""]}], + tests = alltests]; + (Print["\n"]; TestRun[#<>".mt", Loggers -> {VerbosePrintLogger[]}, TestRunTitle -> #]) & /@ tests; Print[]; |