Class FlakyTestRetry

  • All Implemented Interfaces:
    org.testng.IRetryAnalyzer

    public class FlakyTestRetry
    extends Object
    implements org.testng.IRetryAnalyzer
    This class can be used to retry a failed test. It can be useful for flaky tests which are failing for an unknown reason. Example of the usage:
    @Test(retryAnalyzer = FlakyTestRetry.class)
    • Constructor Detail

      • FlakyTestRetry

        public FlakyTestRetry()
    • Method Detail

      • retry

        public boolean retry​(org.testng.ITestResult result)
        Specified by:
        retry in interface org.testng.IRetryAnalyzer