-
Notifications
You must be signed in to change notification settings - Fork 2
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
Load all JUnit test reports, not just the first one #2
Comments
It's working as intended, the action only loads the first valid report file (closest to the project root directory) for each supported format, but I admit this behavior may not be ideal for all use cases. I mainly considered Node.js/Go tools that seem to generate a single aggregated report file most of the time, but that's obviously not the case for Maven/Gradle projects. Parsing all JUnit report files may suit your use case, but not others, e.g. this will break for projects having both aggregated and detailed report files. In a future release, I'll try to :
I could add configuration parameters but I'm trying to make this action as configuration-less as possible to:
In the meantime, as a workaround, you can try to:
I'm open to ideas & suggestions if you have any! I let this issue opened as this feature request is justified and I'd want to find an appropriate solution. |
@GaelGirodon I think it would be nice to have an optional parameter to enable loading all test reports and aggregate the results. In Java projects, I would say it is the most common to have multiple test reports. The change on your side is very simple. Actually, I don't see any valid reason to have this |
If I only make the I've done more research about multiple test runners and none of them seem to produce both a single aggregated report and multiple detailed ones. But nearly all of them may produce multiple report files, by default (e.g. Maven Surefire/Failsafe or Gradle), or in case of sharding. Merging multiple report files seems to always require an additional step, that is most of the time unnecessary because reporting tools generally support multiple input files (e.g. GitLab CI, Maven Surefire Report Plugin, the GitHub action you're using, etc.). So I'm going to modify the action to make it stick to the most common behavior, i.e., load all available test reports. The new version will be released soon, maybe this week, you can preview changes to be released on the |
@GaelGirodon Thank you very much! |
- Improve JUnit test reports loading - Refine file patterns - Load all reports instead of only the first one #2 - Read only top-level `<testsuite>` tags - Exclude some directories from file search - Improve documentation - Clarify explanations about reports loading - Add more examples - Clean code (quotes, semicolons, imports, tests, ...) - Update dependencies - Update ESLint to v9
- Improve JUnit test reports loading - Refine file patterns - Load all reports instead of only the first one #2 - Read only top-level `<testsuite>` tags - Exclude some directories from file search - Improve documentation - Clarify explanations about reports loading - Add more examples - Clean code (quotes, semicolons, tests, ...) - Update dependencies - Update ESLint to v9
- Improve JUnit test reports loading - Refine file patterns - Load all reports instead of only the first one #2 - Read only top-level `<testsuite>` tags - Exclude some directories from file search - Improve documentation - Clarify explanations about reports loading - Add more examples - Clean code (quotes, semicolons, tests, ...) - Update dependencies - Update ESLint to v9
The v1.4.0 has just been released 🎉 @tsantalis Could you please check in your project if the issue is resolved? |
@GaelGirodon It shows a total of 1728 tests passing. I guess the skipped tests are counted as passing. Anyways, it is far better than before! Thank you for your help. |
The v1.5.0 has just been released 🎉 Skipped tests should now be counted and displayed separately, no change is required in the action usage: Thanks @tsantalis for contributing to the improvement of this action through these feature requests and tests on your project! |
@GaelGirodon |
@GaelGirodon
My project has multiple test reports
https://github.com/tsantalis/RefactoringMiner/actions/runs/9143815119/job/25141202337
I added your action in the project's workflow
and it loads only the first one
Is it possible to load all test reports, and save in the json, the total number of passed/failed/skipped tests?
Thank you,
Nikos
The text was updated successfully, but these errors were encountered: