@@ -917,6 +917,7 @@ function run_section()
# to be reported for each test
(echo 1 > $DEBUGFS_MNT/clear_warn_once) > /dev/null 2>&1
+ test_start_time="$(date +"%F %T")"
if [ "$DUMP_OUTPUT" = true ]; then
_run_seq 2>&1 | tee $tmp.out
# Because $? would get tee's return code
@@ -46,8 +46,8 @@ _xunit_make_section_report()
local report=$tmp.report.xunit.$sect_name.xml
# Header
echo "<?xml version=\"1.0\" encoding=\"UTF-8\"?>" > $REPORT_DIR/result.xml
- if [ -n "$date_time" ]; then
- timestamp="$(date -Iseconds --date="$date_time")"
+ if [ -n "$test_start_time" ]; then
+ timestamp="$(date -Iseconds --date="$test_start_time")"
else
timestamp="$(date -Iseconds)"
fi
@@ -61,7 +61,9 @@ _xunit_make_section_report()
name="xfstests"
failures="$bad_count" skipped="$notrun_count" tests="$tests_count" time="$sect_time"
- hostname="$HOST" timestamp="$timestamp">
+ hostname="$HOST"
+ timestamp="$timestamp"
+>
ENDL
# Properties
@@ -184,7 +184,7 @@
</xs:attribute>
<xs:attribute name="timestamp" type="ISO8601_DATETIME_PATTERN" use="required">
<xs:annotation>
- <xs:documentation xml:lang="en">when the test was executed. Timezone must be specified as an offset from UTC.</xs:documentation>
+ <xs:documentation xml:lang="en">Time that the last testcase was started. If no tests are started, this is the time the report was generated. Timezone must be specified as an offset from UTC.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="hostname" use="required">