diff mbox series

[5/5] perf: aggregate: check if subtest exists

Message ID 20230312200856.323688-6-felipe.contreras@gmail.com (mailing list archive)
State New, archived
Headers show
Series perf: fixes and cleanups | expand

Commit Message

Felipe Contreras March 12, 2023, 8:08 p.m. UTC
If no tests were run, for example in p7822-grep-perl-character.sh,
that's not a fatal error, just skip to the next one.

Cc: Christian Couder <chriscool@tuxfamily.org>
Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com>
---
 t/perf/aggregate.perl | 1 +
 1 file changed, 1 insertion(+)
diff mbox series

Patch

diff --git a/t/perf/aggregate.perl b/t/perf/aggregate.perl
index 575d2000cc..a79451a0af 100755
--- a/t/perf/aggregate.perl
+++ b/t/perf/aggregate.perl
@@ -156,6 +156,7 @@  sub sane_backticks {
 	$t =~ s{(?:.*/)?(p(\d+)-[^/]+)\.sh$}{$1} or die "bad test name: $t";
 	my $n = $2;
 	my $fname = "$resultsdir/$t.subtests";
+	next unless (-e $fname);
 	open my $fp, "<", $fname or die "cannot open $fname: $!";
 	for (<$fp>) {
 		chomp;