Class RetryTest
java.lang.Object
org.jboss.arquillian.testng.Arquillian
org.eclipse.microprofile.fault.tolerance.tck.RetryTest
- All Implemented Interfaces:
org.testng.IHookable
,org.testng.ITestNGListener
public class RetryTest
extends org.jboss.arquillian.testng.Arquillian
Test when maxDuration is reached, no more retries will be perfomed. Test the delay and jitter were taken into
consideration.
- Author:
- Emily Jiang
-
Nested Class Summary
Nested classes/interfaces inherited from class org.jboss.arquillian.testng.Arquillian
org.jboss.arquillian.testng.Arquillian.UpdateResultListener
-
Field Summary
Fields inherited from class org.jboss.arquillian.testng.Arquillian
ARQUILLIAN_DATA_PROVIDER
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic org.jboss.shrinkwrap.api.spec.WebArchive
deploy()
void
Analogous to testRetryMaxDuration, testing whether the@Retry
annotation on method serviceB overrides the Class level@Retry
annotation.void
Analogous to testRetryMaxDurationSeconds, testing whether the@Retry
annotation on method serviceB overrides the Class level@Retry
annotation.void
Analogous to testRetryMaxRetries but using a Class level rather than method level annotation.void
void
void
Test maxRetries.void
void
Testing whether the@Retry
annotation on method serviceB overrides the Class level@Retry
annotation.Methods inherited from class org.jboss.arquillian.testng.Arquillian
arquillianAfterClass, arquillianAfterSuite, arquillianAfterTest, arquillianArgumentProvider, arquillianBeforeClass, arquillianBeforeSuite, arquillianBeforeTest, run
-
Constructor Details
-
RetryTest
public RetryTest()
-
-
Method Details
-
deploy
@Deployment public static org.jboss.shrinkwrap.api.spec.WebArchive deploy() -
testRetryMaxRetries
public void testRetryMaxRetries()Test maxRetries. As serviceA is annotated with maxRetries = 5, serviceA should be executed 6 times. -
testRetryMaxDuration
public void testRetryMaxDuration() -
testRetryMaxDurationSeconds
public void testRetryMaxDurationSeconds() -
testRetryWithDelay
public void testRetryWithDelay() -
testRetryWithNoDelayAndJitter
public void testRetryWithNoDelayAndJitter()Testing whether the@Retry
annotation on method serviceB overrides the Class level@Retry
annotation. Delay is 0 and jitter 400ms. Invocation takes 3200ms and effective delay must be between 0 and 400ms. -
testClassLevelRetryMaxRetries
public void testClassLevelRetryMaxRetries()Analogous to testRetryMaxRetries but using a Class level rather than method level annotation. With maxRetries = 2, serviceA should be executed 3 times. -
testClassLevelRetryMaxDuration
public void testClassLevelRetryMaxDuration()Analogous to testRetryMaxDuration, testing whether the@Retry
annotation on method serviceB overrides the Class level@Retry
annotation. Ensure that serviceB is executed more than the maxRetries of 2 specified at the Class level. -
testClassLevelRetryMaxDurationSeconds
public void testClassLevelRetryMaxDurationSeconds()Analogous to testRetryMaxDurationSeconds, testing whether the@Retry
annotation on method serviceB overrides the Class level@Retry
annotation. Ensure that serviceB is executed more than the maxRetries of 2 specified at the Class level.
-