Class DisableAnnotationGloballyEnableOnMethodTest

java.lang.Object
org.jboss.arquillian.testng.Arquillian
org.eclipse.microprofile.fault.tolerance.tck.disableEnv.DisableAnnotationGloballyEnableOnMethodTest
All Implemented Interfaces:
org.testng.IHookable, org.testng.ITestNGListener

public class DisableAnnotationGloballyEnableOnMethodTest extends org.jboss.arquillian.testng.Arquillian
Test that annotations can be disabled at the class level and then re-enabled at the method level.
Author:
Antoine Sabot-Durand, Neil Young, Andrew Rouse
  • 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
    Constructor
    Description
     
  • Method Summary

    Modifier and Type
    Method
    Description
    static org.jboss.shrinkwrap.api.spec.WebArchive
     
    void
    A test to check that asynchronous is enabled
    void
    Test whether Bulkhead is enabled on waitWithBulkhead()
    void
    CircuitBreaker is enabled on the method so the policy should be applied
    void
    Test that a Fallback service is used when service fails.
    void
    failAndRetryOnce is annotated with maxRetries = 1 so it is expected to execute 2 times.
    void
    Test Timeout is enabled, should fail with a timeout exception

    Methods inherited from class org.jboss.arquillian.testng.Arquillian

    arquillianAfterClass, arquillianAfterSuite, arquillianAfterTest, arquillianArgumentProvider, arquillianBeforeClass, arquillianBeforeSuite, arquillianBeforeTest, run

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

    • DisableAnnotationGloballyEnableOnMethodTest

      public DisableAnnotationGloballyEnableOnMethodTest()
  • Method Details

    • deploy

      @Deployment public static org.jboss.shrinkwrap.api.spec.WebArchive deploy()
    • testRetryEnabled

      public void testRetryEnabled()
      failAndRetryOnce is annotated with maxRetries = 1 so it is expected to execute 2 times.
    • testFallbackDisabled

      public void testFallbackDisabled()
      Test that a Fallback service is used when service fails. Retry has been disabled globally and has not been enabled for the method, therefore there should only be one execution
    • testCircuitBreaker

      public void testCircuitBreaker()
      CircuitBreaker is enabled on the method so the policy should be applied
    • testTimeout

      public void testTimeout()
      Test Timeout is enabled, should fail with a timeout exception
    • testAsync

      public void testAsync() throws InterruptedException, ExecutionException
      A test to check that asynchronous is enabled
      Throws:
      InterruptedException - interrupted
      ExecutionException - task was aborted
    • testBulkhead

      public void testBulkhead()
      Test whether Bulkhead is enabled on waitWithBulkhead()