Open tonka3000 opened 3 years ago
Thanks for your pull request. It looks like this may be your first contribution to a Google open source project (if not, look below for help). Before we can look at your pull request, you'll need to sign a Contributor License Agreement (CLA).
:memo: Please visit https://cla.developers.google.com/ to sign.
Once you've signed (or fixed any issues), please reply here with @googlebot I signed it!
and we'll verify it.
ℹ️ Googlers: Go here for more info.
@googlebot I signed it!
The merging of the xml fails, if one of the tests crashes the test itself. Which happens for me with glog and CHECK(...). This creates a SIGABRT. The merge fails because no xml is created for that test.
this would be a great feature for running tests on jenkins.
@JensHuthmann @pbos
I've merged the master branch and resolved the conflicts.
I also skip now files which are empty (0 bytes) when e.g. abort()
is called in a test. This is not a great solution because the existence of the test is now fully hidden from the xml file, but I'm not quite sure how to handle it better. The gtest version I use (1.8.x) don't write a xml file when one of the tests send SIGABRT. Not quite sure if more recent version of gtest make a better job here.
Suggestions are welcome.
Greetings Michael
Sorry for the slow response I've been more busy than I'd like. Can we make sure this error handling is explicit (by comments and printing which tests aborted and that they're therefore not present in the xml output)?
Hi @pbos ,
I will check it (hopefully in the next couple of days).
Such a helpful feature!
@tonka3000 I'm just wondering if you had a chance or if you are planning to finish a work on this PR, so it gets merged?
Hey @mr1sunshine ,
never found the time to finish the PR. Work drifted to different technology and I used gtest rarely since the shift. When somebody want to finish this in the meantime, feel free.
This PR add support for
gtest_output
xml format.gtest support
--gtest_output
to save files as xml. An example would bemy.exe --gtest_output=xml:myfile.xml
. gtest-parallel does not support this option right now, but it would be very practical to have support for it because many CI systems like e.g. GitLab CI support artifact upload to visualize the test results in a project.How a user can use this option
I've added and
--gtest_output
option which is very similar to the original one.Example:
--gtest_output xml:myfile.xml
How is it implemented
I save the gtest xml file for every exectuable run in temp files and join them together after all tasks have finished. This way I get the original content of the gtest xml output which be joined together.
Greetings Michael