Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
lib/test: Fall back to the skip message for test titles
Skips like [1]: ok 23 # skip Insufficient flogiston pressure. are parsed (at least by [email protected]) into structures like: { id: 1, name: "", ok: true, skip: "root.readonly is false but the root filesystem is still not writable" } But title-less tests are not very useful. With this change, cases like the above empty-string name will fall back to the skip value. And if that skip value is undefined, we'll fall back to an empty string (because I'm not sure how well downstream consumers would handle and undefined title). One positive effect of this change is that Mochawesome now has a title message to render for these skips (where previously it just used an empty h4). [1]: https://testanything.org/tap-version-13-specification.html#skipping-tests
- Loading branch information