Class ConditionalFail

  • All Implemented Interfaces:
    org.junit.rules.TestRule

    public class ConditionalFail
    extends AnnotationBasedTestRule
    JUnit rule that inspects the presence of the ShouldFailWhen annotation on a test method. If it finds the annotation, it will modify pass/fail report of test depending on the condition defined in the annotation.
    Author:
    Jiri Pechanec
    • Constructor Detail

      • ConditionalFail

        public ConditionalFail()
    • Method Detail

      • apply

        public org.junit.runners.model.Statement apply​(org.junit.runners.model.Statement base,
                                                       org.junit.runner.Description description)