[PATCH] D84230: [lit] Include total elapsed time in xunit output

Julian Lettner via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed Jul 22 12:08:13 PDT 2020


yln accepted this revision.
yln added a comment.
This revision is now accepted and ready to land.

LGTM, thanks!



================
Comment at: llvm/utils/lit/lit/reports.py:83
             file.write('<?xml version="1.0" encoding="UTF-8"?>\n')
-            file.write('<testsuites>\n')
+            file.write('<testsuites time="{time:.2f}">\n'.format(time=elapsed))
             for suite, test_iter in tests_by_suite:
----------------
Note: I initially didn't include the overall time here because it is measured by simply doing the following in `main.py`:
```
    start = time.time()
    run_tests(...)
    elapsed = time.time() - start
```

So it's not necessarily exactly equal to the sum of all the individual test times.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D84230/new/

https://reviews.llvm.org/D84230





More information about the llvm-commits mailing list