This repository has been archived by the owner on Nov 10, 2023. It is now read-only.
Use original JUnit test class name instead of suite class in test XML report #2624
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.
As discussed in #2623, this change will use the original test class name instead of the test suite name when generating the test output XML when run against a JUnit suite. I've based this change on the
dev
branch as it doesn't seem the kind of thing that needs to hit the stable branch urgently.I've tried to keep the change as small as possible by overloading the
TestCaseSummary
constructor to default the newtestSuite
parameter tofalse
, so that all the other usages of this aren't affected, but if it's better to push this default up to the places where this class is instantiated then I can do that instead!One thing to note: I originally built this change on top of
master
, but figured that it was probably better suited todev
. It all seemed to work for me on the stable build, however since rebasing the change onto thedev
branch I can no longer build the project? I don't know if this is because I'm trying to build using the latest Buck release, but it gives me an error parsingbuck/programs/defs.bzl
(name 'name' is not defined
).