From: Viktor Szakats Date: Thu, 8 Aug 2024 12:42:40 +0000 (+0200) Subject: runtests: log ignored but passed tests X-Git-Tag: curl-8_10_0~274 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=1a444e3153c739de45f5d97aeb9d52c0ddd4d978;p=thirdparty%2Fcurl.git runtests: log ignored but passed tests List tests explicitly ignored, but passing. It can be useful to catch ignore rules that are no longer necessary because the tests are not failing anymore. To not clutter the default view, hide this information under a GitHub Actions foldable group. Closes #14457 --- diff --git a/tests/runtests.pl b/tests/runtests.pl index dccb8463b7..64f6f941a7 100755 --- a/tests/runtests.pl +++ b/tests/runtests.pl @@ -144,6 +144,8 @@ my %disabled; # disabled test cases my %ignored; # ignored results of test cases my %ignoretestcodes; # if test results are to be ignored +my $passedign; # tests passed with results ignored + my $timestats; # time stamping and stats generation my $fullstats; # show time stats for every single test my %timeprepini; # timestamp for each test preparation start @@ -1776,6 +1778,8 @@ sub singletest_success { } if($errorreturncode==2) { + # ignored test success + $passedign .= "$testnum "; logmsg "Warning: test$testnum result is ignored, but passed!\n"; } } @@ -3079,10 +3083,18 @@ sub testnumdetails { } if($total) { + if($passedign) { + my $sorted = numsortwords($passedign); + logmsg "::group::Passed Ignored Test details\n"; + testnumdetails("PASSED-IGNORED", $sorted); + logmsg "IGNORED: passed tests: $sorted\n"; + logmsg "::endgroup::\n"; + } + if($failedign) { - my $failedignsorted = numsortwords($failedign); - testnumdetails("FAIL-IGNORED", $failedignsorted); - logmsg "IGNORED: failed tests: $failedignsorted\n"; + my $sorted = numsortwords($failedign); + testnumdetails("FAIL-IGNORED", $sorted); + logmsg "IGNORED: failed tests: $sorted\n"; } logmsg sprintf("TESTDONE: $ok tests out of $total reported OK: %d%%\n", $ok/$total*100);