Package testUtils

Class RetryAnalyzer

java.lang.Object
testUtils.RetryAnalyzer
All Implemented Interfaces:
org.testng.IRetryAnalyzer

public class RetryAnalyzer extends Object implements org.testng.IRetryAnalyzer
Retry analyzer for TestNG tests to handle HTTP 429 responses.
  • Constructor Details

    • RetryAnalyzer

      public RetryAnalyzer()
  • Method Details

    • retry

      public boolean retry(org.testng.ITestResult result)
      Retries the test if the status code is 429 (Too Many Requests) and retry count is not exceeded.
      Specified by:
      retry in interface org.testng.IRetryAnalyzer
      Parameters:
      result - the test result
      Returns:
      true if the test should be retried, false otherwise