summaryrefslogtreecommitdiff
path: root/common/tests/run-test.pl
diff options
context:
space:
mode:
authorschodet2007-05-09 09:39:54 +0000
committerschodet2007-05-09 09:39:54 +0000
commit53cfc0aeabc8acbbc886716cee0c82deea195018 (patch)
tree65c724dca6dba7ca831ef969cfbb8ec73d22c9f4 /common/tests/run-test.pl
parent2b8a927fc1e4c5491d731a589b20d06e52509ef5 (diff)
Added new test system.
Added ccache support. git-svn-id: svn+ssh://pessac/svn/cesar/trunk@93 017c9cb6-072f-447c-8318-d5b54f68fe89
Diffstat (limited to 'common/tests/run-test.pl')
-rwxr-xr-xcommon/tests/run-test.pl18
1 files changed, 7 insertions, 11 deletions
diff --git a/common/tests/run-test.pl b/common/tests/run-test.pl
index 70f57b12e8..b378cab11d 100755
--- a/common/tests/run-test.pl
+++ b/common/tests/run-test.pl
@@ -12,19 +12,15 @@ my $i = 0;
defined $Config{sig_name} || die "No sigs?";
$signame[$i++] = $_ foreach split (' ', $Config{sig_name});
-my $clean_only = 0;
-
-if (@ARGV && $ARGV[0] eq 'clean')
-{
- $clean_only = 1;
- shift @ARGV;
-}
-
my $base = getcwd . '/' . shift @ARGV;
my $dir;
my $fail = 0;
-while (<>)
+my %only;
+
+@only{@ARGV} = ();
+
+while (<STDIN>)
{
chomp;
next if /^\s*(?:#.*)?$/;
@@ -38,13 +34,12 @@ while (<>)
$dir = $1;
chdir "$base/$dir"
or die "cannot change directory";
- push @ungeted, '%-make -s clean' unless $2;
+ push @ungeted, '-clean: make -s clean' unless $2;
}
else
{
defined $dir
or die "bad format";
- next unless s/^%// || !$clean_only;
my ($dontcare, $expected) = (0, '');
$dontcare = 1 if s/^-//;
$expected = ' (expected)' if s/^!//;
@@ -52,6 +47,7 @@ while (<>)
/^(.*): (.*)$/
and ($name, $cmd) = ($1, $2)
or ($name, $cmd) = ($_, $_);
+ next if %only && !exists $only{$name};
my $t = "=> $dir - $name";
print "\n$t\n";
system ($cmd);