-
-
Notifications
You must be signed in to change notification settings - Fork 1.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Allow attaching files to test results #4138
Merged
Merged
Conversation
This file contains 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
19 tasks
marcphilipp
force-pushed
the
marc/file-attachments
branch
9 times, most recently
from
November 20, 2024 17:43
b9c6322
to
e6ad7bc
Compare
Moreover, when an output dir is configured explicitly it's now used without creating another subdirectory. A new `{uniqueNumber}` placeholder may be used to create a unique directory per test execution. This may be used by build tools that create multiple forks to run tests in parallel.
Should be fixed properly in #3040
marcphilipp
force-pushed
the
marc/file-attachments
branch
from
November 26, 2024 08:55
b585d12
to
e35de2e
Compare
marcphilipp
force-pushed
the
marc/file-attachments
branch
from
November 26, 2024 09:27
8ddc816
to
75fc69b
Compare
marcphilipp
force-pushed
the
marc/file-attachments
branch
from
November 26, 2024 09:33
75fc69b
to
4dc74dd
Compare
marcphilipp
force-pushed
the
marc/file-attachments
branch
from
November 26, 2024 09:35
4dc74dd
to
a3ac17b
Compare
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.
Overview
Being able to attach files such as screenshots or extra log files to a test is useful to diagnose the outcome of tests. This PR adds an API for Jupiter test authors to do so (
TestReporter.publishFile
) and includes it when writing the Open Test Reporting XML output (inOpenTestReportGeneratingListener
) via a new method onTestExecutionListener
. Moreover, it addsOutputDirectoryProvider
toEngineDiscoveryRequest
so other engines can also attach files and write them to the same output directory and makes it available toTestExecutionListener
implementations viaTestPlan
. The default location of the XML output is changed fromOUTPUT_DIR/junit-platform-events-*.xml
toOUTPUT_DIR/junit-*/open-test-report.xml
.I hereby agree to the terms of the JUnit Contributor License Agreement.
Definition of Done
@API
annotations