From da2f1dd9580d1aa0ba9213652614caf89e1dbf78 Mon Sep 17 00:00:00 2001 From: allen Date: Tue, 23 Apr 2002 20:57:15 +0000 Subject: Can now set absolute or relative tolerance for all runs ... need to work out still how to get to this menu in other cases and how to add this information to the end summary, and whether a testsuite should be able to set it's tolerance itself etc. git-svn-id: http://svn.cactuscode.org/flesh/trunk@2748 17b73243-c579-4c4c-a9d2-2d5706c11dac --- lib/sbin/RunTest.pl | 34 +++++++++++++++++++++++++++++----- 1 file changed, 29 insertions(+), 5 deletions(-) (limited to 'lib/sbin/RunTest.pl') diff --git a/lib/sbin/RunTest.pl b/lib/sbin/RunTest.pl index 8e5b814c..43699eb3 100644 --- a/lib/sbin/RunTest.pl +++ b/lib/sbin/RunTest.pl @@ -120,13 +120,37 @@ while ($choice !~ /^Q/i) print " Options for customization\n"; if ($test) { - print " Change tolerance for this run ($test) [R]\n"; + while ($choice !~ /^[AR]/i) + { + print " Change absolute tolerance for this run ($test) [A]\n"; + print " Change relative tolerance for this run ($test) [R]\n"; + $choice = &defprompt(" Select choice: ",""); + if ($choice =~ /A/i) + { + $runconfig{"$thorn $test ABSTOL"} = &defprompt(" New absolute tolerance: ","$runconfig{\"$thorn $test ABSTOL\"}"); + } + elsif ($choice =~ /R/i) + { + $runconfig{"$thorn $test RELTOL"} = &defprompt(" New relative tolerance: ","$runconfig{\"$thorn $test RELTOL\"}"); + } + } } - print " Change tolerance from $rundata->{\"TOLERANCE\"} for all further runs [T]\n"; - $choice = &defprompt(" Select choice: ",""); - if ($choice =~ /T/i) + else { - $rundata->{"TOLERANCE"} = &defprompt(" New tolerance: ","$rundata->{\"TOLERANCE\"}"); + while ($choice !~ /^[AR]/i) + { + print " Change absolute tolerance from $runconfig{\"ABSTOL\"} for all further runs [A]\n"; + print " Change relative tolerance from $runconfig{\"RELTOL\"} for all further runs [R]\n"; + $choice = &defprompt(" Select choice: ",""); + if ($choice =~ /^A/i) + { + $runconfig{"ABSTOL"} = &defprompt(" New absolute tolerance: ","$runconfig{\"ABSTOL\"}"); + } + elsif ($choice =~ /^R/i) + { + $runconfig{"RELTOL"} = &defprompt(" New relative tolerance: ","$runconfig{\"RELTOL\"}"); + } + } } } elsif ($choice =~ /^Q/i) -- cgit v1.2.3