Class TestExecutionResultConditions


  • @API(status=MAINTAINED,
         since="1.7")
    public final class TestExecutionResultConditions
    extends java.lang.Object
    Collection of AssertJ conditions for TestExecutionResult.
    Since:
    1.4
    See Also:
    EventConditions
    • Method Summary

      All Methods Static Methods Concrete Methods 
      Modifier and Type Method Description
      private static org.assertj.core.api.Condition<java.lang.Throwable> cause​(org.assertj.core.api.Condition<java.lang.Throwable> condition)  
      static org.assertj.core.api.Condition<java.lang.Throwable> cause​(org.assertj.core.api.Condition<java.lang.Throwable>... conditions)
      Create a new Condition that matches if and only if a Throwable's cause matches all supplied conditions.
      static org.assertj.core.api.Condition<java.lang.Throwable> instanceOf​(java.lang.Class<? extends java.lang.Throwable> expectedType)
      Create a new Condition that matches if and only if a Throwable is an instance of the supplied Class.
      static org.assertj.core.api.Condition<java.lang.Throwable> message​(java.lang.String expectedMessage)
      Create a new Condition that matches if and only if a Throwable's message is equal to the supplied String.
      static org.assertj.core.api.Condition<java.lang.Throwable> message​(java.util.function.Predicate<java.lang.String> expectedMessagePredicate)
      Create a new Condition that matches if and only if a Throwable's message matches the supplied Predicate.
      static org.assertj.core.api.Condition<TestExecutionResult> status​(TestExecutionResult.Status expectedStatus)
      Create a new Condition that matches if and only if a TestExecutionResult's status is equal to the supplied Status.
      private static org.assertj.core.api.Condition<java.lang.Throwable> suppressed​(int index, org.assertj.core.api.Condition<java.lang.Throwable> condition)  
      static org.assertj.core.api.Condition<java.lang.Throwable> suppressed​(int index, org.assertj.core.api.Condition<java.lang.Throwable>... conditions)
      Create a new Condition that matches if and only if a Throwable's suppressed throwable at the supplied index matches all supplied conditions.
      private static org.assertj.core.api.Condition<TestExecutionResult> throwable​(org.assertj.core.api.Condition<? super java.lang.Throwable> condition)  
      static org.assertj.core.api.Condition<TestExecutionResult> throwable​(org.assertj.core.api.Condition<java.lang.Throwable>... conditions)
      Create a new Condition that matches if and only if a TestExecutionResult's throwable matches all supplied conditions.
      • Methods inherited from class java.lang.Object

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

      • TestExecutionResultConditions

        private TestExecutionResultConditions()
    • Method Detail

      • throwable

        @SafeVarargs
        public static org.assertj.core.api.Condition<TestExecutionResult> throwable​(org.assertj.core.api.Condition<java.lang.Throwable>... conditions)
        Create a new Condition that matches if and only if a TestExecutionResult's throwable matches all supplied conditions.
      • cause

        @SafeVarargs
        public static org.assertj.core.api.Condition<java.lang.Throwable> cause​(org.assertj.core.api.Condition<java.lang.Throwable>... conditions)
        Create a new Condition that matches if and only if a Throwable's cause matches all supplied conditions.
      • suppressed

        @SafeVarargs
        public static org.assertj.core.api.Condition<java.lang.Throwable> suppressed​(int index,
                                                                                     org.assertj.core.api.Condition<java.lang.Throwable>... conditions)
        Create a new Condition that matches if and only if a Throwable's suppressed throwable at the supplied index matches all supplied conditions.
      • instanceOf

        public static org.assertj.core.api.Condition<java.lang.Throwable> instanceOf​(java.lang.Class<? extends java.lang.Throwable> expectedType)
        Create a new Condition that matches if and only if a Throwable is an instance of the supplied Class.
      • message

        public static org.assertj.core.api.Condition<java.lang.Throwable> message​(java.lang.String expectedMessage)
        Create a new Condition that matches if and only if a Throwable's message is equal to the supplied String.
      • message

        public static org.assertj.core.api.Condition<java.lang.Throwable> message​(java.util.function.Predicate<java.lang.String> expectedMessagePredicate)
        Create a new Condition that matches if and only if a Throwable's message matches the supplied Predicate.
      • throwable

        private static org.assertj.core.api.Condition<TestExecutionResult> throwable​(org.assertj.core.api.Condition<? super java.lang.Throwable> condition)
      • cause

        private static org.assertj.core.api.Condition<java.lang.Throwable> cause​(org.assertj.core.api.Condition<java.lang.Throwable> condition)
      • suppressed

        private static org.assertj.core.api.Condition<java.lang.Throwable> suppressed​(int index,
                                                                                      org.assertj.core.api.Condition<java.lang.Throwable> condition)