| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
|
Review requested:
|
Sorry, something went wrong.
There was a problem hiding this comment.
Perhaps this should be tested with a .snapshot (see example
)
Sorry, something went wrong.
Signed-off-by: Lazizbek Ergashev <lazerg2@gmail.com>
|
Switched to a snapshot in 0a00f28. test/test-runner/test-output-junit-empty-diagnostic.mjs now compares against junit_empty_diagnostic.snapshot, which pins both the empty <!-- --> comment and the closing </testsuites>. That replaced the assertion-based case I had in test-runner-reporters.js, so I squashed the branch back into one commit. |
Sorry, something went wrong.
Sorry, something went wrong.
Codecov Report✅ All modified and coverable lines are covered by tests. @@ Coverage Diff @@
## main #65357 +/- ##
==========================================
- Coverage 90.12% 90.11% -0.01%
==========================================
Files 752 752
Lines 251865 251872 +7
Branches 47353 47362 +9
==========================================
- Hits 226991 226984 -7
+ Misses 16223 16213 -10
- Partials 8651 8675 +24
... and 30 files with indirect coverage changes 🚀 New features to boost your workflow:
|
Sorry, something went wrong.
Sorry, something went wrong.
| Back | FazBrowse Home | New Git URL |
context.diagnostic('') makes the junit reporter throw. treeToXML guards the comment branch with if (comment), so an empty message falls through to the element branch and ObjectEntries(attrs) gets called on undefined. The generator dies, the destination stream is destroyed, and the report is left without its closing </testsuites>.
Comment nodes are already identified by comment == null elsewhere in the reporter, so the guard now checks the same way and an empty diagnostic renders as an empty XML comment.
Fixes: #65355