Generate testng-results.xml per test suite

61 views
Skip to first unread message

Bojan S

unread,
Apr 28, 2023, 6:26:11 AM4/28/23
to testng-users
Hello guys I am exploring possibility to generate separate testng-results.xml files per suite inside of the parent suite.
Here is the example of the parent test suite, it contains 3 child test suites:

<suite name="Regression parallel" verbose="1">
<suite-files>
<suite-file path="regression_1.xml"/>
<suite-file path="regression_2.xml"/>
<suite-file path="regression_3.xml"/>
</suite-files>
</suite>

I would like to generate separate testng-results.xml file per each child suite, so after execution, I would like to have 3 separate .xml results files, for example
testng-results-regression_1.xml
testng-results-regression_2.xml
testng-results-regression_3.xml

Instead of just one testng-results.xml

Does testNG support something like this out of the box?
And if not, I would really appreciate some guidelines.

Cheers!

Bojan

⇜Krishnan Mahadevan⇝

unread,
Apr 28, 2023, 6:28:37 AM4/28/23
to testng...@googlegroups.com
Bojan,

Can you please file this as an issue on the TestNG github page? This looks like a genuine request and given the fact that the xmls in question are being natively generated by TestNG, it would be a reasonable expectation to see TestNG do this.

To answer your question, currently TestNG does not do this out of the box.


Thanks & Regards
Krishnan Mahadevan

"All the desirable things in life are either illegal, expensive, fattening or in love with someone else!"
My Scribblings @ http://wakened-cognition.blogspot.com/
My Technical Scribblings @ https://rationaleemotions.com/


--
You received this message because you are subscribed to the Google Groups "testng-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to testng-users...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/testng-users/725c2fe8-7aba-4761-9e44-04d55057c0fbn%40googlegroups.com.

⇜Krishnan Mahadevan⇝

unread,
May 4, 2023, 2:48:38 AM5/4/23
to testng...@googlegroups.com
I went ahead and logged an issue on your behalf : https://github.com/testng-team/testng/issues/2906


Thanks & Regards
Krishnan Mahadevan

"All the desirable things in life are either illegal, expensive, fattening or in love with someone else!"
My Scribblings @ http://wakened-cognition.blogspot.com/
My Technical Scribblings @ https://rationaleemotions.com/

Bojan S

unread,
May 24, 2023, 4:04:28 AM5/24/23
to testng-users
Hi Krishnan,

Thank you!

New version is released with suggested changes, tried it, works like a charm!

Cheers,

Bojan
Reply all
Reply to author
Forward
0 new messages