-
Notifications
You must be signed in to change notification settings - Fork 395
New issue
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
Adds option to allow prefixing the class name in an xunit report #968
Conversation
This patch implement a very valuable and long requested feature (#402). I have the same problem that Jenkins only shows the |
self.configure([ | ||
"--with-xunit", | ||
"--xunit-file=%s" % self.xmlfile, | ||
"--xunit-prefix-with-testsuite-name" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This all looks good with one exception: I expected to see a test that uses xunit-testsuite-name to change the prefix. Do you mind adding such a test?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I thought adding the default would be enough. Additional test is in ab198aa
0214d2e
to
ab198aa
Compare
@jszakmeister I added the additional test in ab198aa and rebased to master |
Great! Thanks! |
Adds option to allow prefixing the class name in an xunit report
Thanks for integrating! |
Great! Can I assume that this will be released in 1.3.8 at some point in the future? |
Hopefully. I'm not making any promises--I'm stepping down as maintainer soon. |
In a matrixed build environment (for example running tests with
tox
) and producing multiple xunit reports, a report crawler (for example from Bamboo) can not distinguish between results in different environments, because the class name is always the same.In order to allow distinguishing between failures in different environments, this PR adds an option
--xunit-prefix-with-testsuite-name
to thenose-xunit
plugin.A test result looking like this with
--with-xunit
:becomes:
with
--with-xunit --xunit-prefix-with-testsuite-name
or:
with
--with-xunit --xunit-testsuite-name=foo --xunit-prefix-with-testsuite-name
.Side note: It works in a similar manner as the
useBrowserName
option in the karma-junit-reporter.Fixes #402