Class TogglesAwareTestRule
java.lang.Object
com.adobe.cq.testing.junit.rules.toggles.TogglesAwareTestRule
- All Implemented Interfaces:
org.junit.rules.TestRule
Junit rule for filtering tests based on the toggles enabled on the remote instance.
The rule is used in combination with the annotations
The rule is used in combination with the annotations
RunIfToggleEnabled
and
SkipIfToggleEnabled
.
If both annotations are applied to a test, both conditions must be met (AND operation).- See Also:
-
Constructor Summary
ConstructorDescriptionTogglesAwareTestRule
(Supplier<org.apache.sling.testing.clients.SlingClient> clientSupplier) -
Method Summary
Modifier and TypeMethodDescriptionorg.junit.runners.model.Statement
apply
(org.junit.runners.model.Statement base, org.junit.runner.Description description) protected boolean
shouldRunTest
(org.junit.runner.Description description)
-
Constructor Details
-
TogglesAwareTestRule
-
-
Method Details
-
apply
public org.junit.runners.model.Statement apply(org.junit.runners.model.Statement base, org.junit.runner.Description description) - Specified by:
apply
in interfaceorg.junit.rules.TestRule
-
shouldRunTest
protected boolean shouldRunTest(org.junit.runner.Description description)
-