Commit 79a1fab
committed
[llvm][llvm-lit] Add total time for each testsuite in JUnit XML output
Currently we write out a time taken to run all test suites:
<testsuites time="8.28">
And one for each test:
<testcase classname="lldb-shell.Breakpoint" name="breakpoint-command.test" time="2.38"/>
However, the schema says there should be one for each suite and test, but
none for testsuites:
https://github.com/windyroad/JUnit-Schema/blob/cfa434d4b8e102a8f55b8727b552a0063ee9044e/JUnit.xsd#L216
I'm leaving the testsuites time in though because no one has complained
so far, and someone out there probably has a script relying on it by now.
Most XML tools handle unknown attributes quite well anyway.
I'm adding a per testsuite time to comply with the schema and maybe
be more compatible with other JUnit tools.
<testsuite name="lldb-shell" ... time="12.34">
The test suite time is the sum of the time taken for all tests in the
suite. This will ignore some overhead in setting up the suite, and
means that the sum of the times for all invidual suites may not
equal the testsuites time.
As we're usually focusing on the execution time of particular tests,
not lit's book keeping, I think this is a reasonable choice.1 parent 8e5aa53 commit 79a1fab
File tree
3 files changed
+13
-5
lines changed- llvm/utils/lit
- lit
- tests
3 files changed
+13
-5
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
105 | 105 | | |
106 | 106 | | |
107 | 107 | | |
108 | | - | |
109 | | - | |
| 108 | + | |
| 109 | + | |
| 110 | + | |
| 111 | + | |
| 112 | + | |
| 113 | + | |
| 114 | + | |
| 115 | + | |
| 116 | + | |
| 117 | + | |
110 | 118 | | |
111 | 119 | | |
112 | 120 | | |
113 | | - | |
| 121 | + | |
114 | 122 | | |
115 | 123 | | |
116 | 124 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
107 | 107 | | |
108 | 108 | | |
109 | 109 | | |
110 | | - | |
| 110 | + | |
111 | 111 | | |
112 | 112 | | |
113 | 113 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
9 | 9 | | |
10 | 10 | | |
11 | 11 | | |
12 | | - | |
| 12 | + | |
13 | 13 | | |
14 | 14 | | |
15 | 15 | | |
| |||
0 commit comments