Annotation Interface EnableRift


Enables the rift-java Spring test integration on a test class: starts one Rift engine for the (cacheable) Spring test context and drives the ConfigureImposter declarations.

The annotation attributes are the Spring context-cache key contributor (see RiftContextCustomizer#equals); two test classes with identical @EnableRift/ @ConfigureImposter configuration share one application context and therefore one engine.

Meta-annotated with @ExtendWith(RiftParameterResolver) so InjectImposter/InjectRift resolve as @Test method parameters with no extra @ExtendWith — parity with the field injection driven by RiftTestExecutionListener.

  • Element Details

    • transport

      Transport transport
      How to obtain the engine.
      Default:
      AUTO
    • adminUri

      String adminUri
      Admin API URI for Transport.CONNECT (and Transport.AUTO when set). Supports ${property} placeholders resolved against the test context environment.
      Default:
      ""
    • reset

      Reset reset
      When configured imposters are reset during a test class run.
      Default:
      PER_TEST