Repository navigation
catch_discover_tests reads the listing from stdout under Emscripten - #3242
Open
nafiurahman00 wants to merge 1 commit into
Open
nafiurahman00 wants to merge 1 commit into
nafiurahman00 wants to merge 1 commit into
Conversation
Since 3.16 the test listing is written to a temp file and read back. Emscripten binaries run under node with a virtual filesystem, so the file never shows up on disk and discovery fails. When targeting Emscripten, ask for the listing on stdout instead. Closes catchorg#3241
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## devel #3242 +/- ##
==========================================
- Coverage 91.43% 91.39% -0.03%
==========================================
Files 205 205
Lines 9108 9108
==========================================
- Hits 8327 8324 -3
- Misses 781 784 +3 🚀 New features to boost your workflow:
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
I went with the first option from #3241. When
CMAKE_SYSTEM_NAMEisEmscripten, discovery asks for the listing on stdout like it did before 3.16, so the temp file doesn't get lost in node's virtual filesystem. It doesn't change anything for other platforms.A small heads-up I would like to give is, it has to be
%stdout, not%stdout%. The second one gets rejected as an unknown stream, so discovery still fails with it.I checked it with emsdk 7.0.0 on a small two-test project. Before this, POST_BUILD broke the build and PRE_TEST failed in ctest. Now both work. The normal test suite passes still. CI has no Emscripten job, so there's no new test here. If you'd rather have a general option than special-casing Emscripten, I can switch it.
GitHub Issues
Closes #3241