Run test suites with a single call to run-test-suites.pl
Before this commit, `make test` stopped after running the TLS tests if there
was a failure.
Have `run-test-suites.pl` take care of looking in all the directories, so
that the last line of output from `make test` is an accurate report of all
the test suites, not just the test suites from the last run of
`run-test-suites.pl`.
Signed-off-by: Gilles Peskine <Gilles.Peskine@arm.com>
diff --git a/tests/scripts/run-test-suites.pl b/tests/scripts/run-test-suites.pl
index 408deaf..8274210 100755
--- a/tests/scripts/run-test-suites.pl
+++ b/tests/scripts/run-test-suites.pl
@@ -40,7 +40,8 @@
# All test suites = executable files with a .datax file.
my @suites = ();
-for my $data_file (glob 'test_suite_*.datax') {
+my @test_dirs = qw(../tf-psa-crypto/tests .);
+for my $data_file (map {glob "$_/test_suite_*.datax"} @test_dirs) {
(my $base = $data_file) =~ s/\.datax$//;
push @suites, $base if -x $base;
push @suites, "$base.exe" if -e "$base.exe";
@@ -82,8 +83,10 @@
print $padchar x( $padlen ), " $string ", $padchar x( $padlen ), "\n";
}
-for my $suite (@suites)
+for my $suite_path (@suites)
{
+ my $suite = $suite_path;
+ $suite =~ s!.*/!!;
print "$suite ", "." x ( 72 - length($suite) - 2 - 4 ), " ";
if( $suite =~ /$skip_re/o ) {
print "SKIP\n";
@@ -91,7 +94,7 @@
next;
}
- my $command = "$prefix$suite";
+ my $command = "$prefix$suite_path";
if( $verbose ) {
$command .= ' -v';
}