From: Theodore Ts'o Date: Mon, 2 Oct 2017 03:39:32 +0000 (-0400) Subject: report: fix summary statistics in xUnit header X-Git-Tag: v2022.05.01~1847 X-Git-Url: https://www.infradead.org/git/?a=commitdiff_plain;h=48d7ba426e6de4723b8508a723f774aed3c99afd;p=users%2Fhch%2Fxfstests-dev.git report: fix summary statistics in xUnit header The xUnit XML DTD distinguishes between test failures and test errors, where a test failure indicate that the test has explicitly indicated that the code under test has behaved in an unexpected fashion, whereas a test error indicates the test code itself has thrown an error or there has been some other test implementation error. Xfstest failures are correctly marked as xUnit failures, but in the attributes of the testsuite XML element, the number of test failures was incorrectly reported as the number of errors. Signed-off-by: Theodore Ts'o Cc: Dmitry Monakhov Reviewed-by: Eryu Guan Signed-off-by: Eryu Guan --- diff --git a/common/report b/common/report index bb689836a..058c0bba6 100644 --- a/common/report +++ b/common/report @@ -59,7 +59,7 @@ _xunit_make_section_report() # Header echo "" > $REPORT_DIR/result.xml local dtime=`echo $date_time| tr " " 'T'` - local stats="errors=\"$n_bad\" skipped=\"$n_notrun\" tests=\"$n_total\" time=\"$sect_time\"" + local stats="failures=\"$n_bad\" skipped=\"$n_notrun\" tests=\"$n_total\" time=\"$sect_time\"" local hw_info="hostname=\"$HOST\" timestamp=\"$dtime\" " echo "" >> $REPORT_DIR/result.xml