Skip to content

Instantly share code, notes, and snippets.

@SarahElson
Created April 11, 2024 08:15
Show Gist options
  • Select an option

  • Save SarahElson/4169359b24e56d338b233de15f20abeb to your computer and use it in GitHub Desktop.

Select an option

Save SarahElson/4169359b24e56d338b233de15f20abeb to your computer and use it in GitHub Desktop.
How To Retry Failed Tests Using IRetryAnalyzer In TestNG
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE suite SYSTEM "https://testng.org/testng-1.0.dtd">
<suite name="Failed suite [LambdaTest ecommerce playground website test suite ]" guice-stage="DEVELOPMENT">
<listeners>
<listener class-name="io.github.mfaisalkhatri.listeners.RetryListener"/>
</listeners>
<test thread-count="5" name="Search Product tests (failed)">
<parameter name="browser" value="remote_chrome_lambdatest"/>
<classes>
<class name="io.github.mfaisalkhatri.tests.retrytests.RetryFailedTests">
<methods>
<include name="setupTest"/>
<include name="tearDown"/>
<include name="setupTests"/>
<include name="testSearchProduct"/>
</methods>
</class> <!-- io.github.mfaisalkhatri.tests.retrytests.RetryFailedTests -->
</classes>
</test> <!-- Search Product tests (failed) -->
</suite> <!-- Failed suite [LambdaTest ecommerce playground website test suite ] -->
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment