From 298f781948d4bd69cfe826ce86de907ac9dbb6c2 Mon Sep 17 00:00:00 2001 From: Gilles Peskine Date: Tue, 15 Nov 2022 23:54:26 +0100 Subject: [PATCH] Use .datax for `make test`, not .data Looking for the .data file doesn't work in out-of-tree builds. Use the .datax file instead. `make clean` removes all .datax files, so this resolves the issue of executables not present on the current branch being left behind after a branch change followed by a `make clean`. Signed-off-by: Gilles Peskine --- tests/scripts/run-test-suites.pl | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/tests/scripts/run-test-suites.pl b/tests/scripts/run-test-suites.pl index 8a5bb937dc..cedc0bfa5a 100755 --- a/tests/scripts/run-test-suites.pl +++ b/tests/scripts/run-test-suites.pl @@ -50,10 +50,10 @@ GetOptions( 'verbose|v:1' => \$verbose, ) or die; -# All test suites = executable files derived from a .data file. +# All test suites = executable files with a .datax file. my @suites = (); -for my $data_file (glob 'suites/test_suite_*.data') { - (my $base = $data_file) =~ s#^suites/(.*)\.data$#$1#; +for my $data_file (glob 'test_suite_*.datax') { + (my $base = $data_file) =~ s/\.datax$//; push @suites, $base if -x $base; push @suites, "$base.exe" if -e "$base.exe"; }