I need to run nosetests on 2 packages seperately. For example:
nosetests --with-xunit --xunit-file=sample.xml test_sample.py
and
nosetests --with-xunit --xunit-file=sample1.xml test_sample1.py
Now how can I combine sample.xml and sample1.xml files?
Is there any command to do that? I need a combined test result file in xml so that I can use that file in jenkins configuration.
You can have multiple test result (sample.xml
and sample1.xml
) in jenkins. Just set Publish JUnit test result report\Test report XMLs
to select all xml reports with **/*.xml
, and generate your xml output within your workspace, something like:
nosetests --with-xunit --xunit-file=%WORKSPACE%\\sample.xml test_sample.py
nosetests --with-xunit --xunit-file=%WORKSPACE%\\sample1.xml test_sample1.py
You can use the xunitmerge package to do this.
xunitmerge sample.xml sample1.xml merged.xml
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With