TestNg-Rerunning Skipped Test cases (On Configuration Failures)

419 views
Skip to first unread message

santhosh soma

unread,
Oct 16, 2017, 7:44:10 AM10/16/17
to testng...@googlegroups.com
Hello All,

We have implemented Recovery/Retry Mechanism for the Failure test cases. We are successful so far for the re running failure test cases from the end to end.

At the same time,  TestNG is marking the test cases as Skipped if any before configuration method fails. Due to this, Retry Listener is not picking up the skipped tests.

Is there any possible way to handle this? 

Thanks
Santhosh.

Krishnan Mahadevan

unread,
Oct 16, 2017, 9:35:50 AM10/16/17
to testng...@googlegroups.com

Are you looking for a retry mechanism for a configuration method?

 

Retrying is applicable only for failed tests and not for skipped tests.

 

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 Scribbings @ http://rationaleemotions.wordpress.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 post to this group, send email to testng...@googlegroups.com.
Visit this group at https://groups.google.com/group/testng-users.
For more options, visit https://groups.google.com/d/optout.

santhosh soma

unread,
Oct 24, 2017, 12:37:51 AM10/24/17
to testng...@googlegroups.com
Hi Krishnan,

Thanks for the quick response. Yes I am looking for the retry mechanism for a configuration method failure.

Yes I am aware of Retrying is applicable only for failed test and not for skipped tests.

Thanks
Santhosh.

⇜Krishnan Mahadevan⇝

unread,
Oct 24, 2017, 1:27:14 AM10/24/17
to testng...@googlegroups.com
I don't think there is any such mechanism out there. So you can perhaps build it on your own, by having a loop based retry mechanism (which tries "n" times before giving up), within your configuration methods, which retries until either the config passes or n attempts have been made.

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 Scribbings @ http://rationaleemotions.wordpress.com/

To unsubscribe from this group and stop receiving emails from it, send an email to testng-users+unsubscribe@googlegroups.com.

Santosh Bhinge

unread,
Nov 27, 2017, 5:04:38 AM11/27/17
to testng-users
Hi Santhosh,

Looking for the solutions of retrying skipped tests along with failed, as you put the query for. Any better luck? if yes please do share. Thanks.
Reply all
Reply to author
Forward
0 new messages