Class ShouldContainValue

  • All Implemented Interfaces:
    ErrorMessageFactory

    public class ShouldContainValue
    extends BasicErrorMessageFactory
    Creates an error message indicating that an assertion that verifies a map contains a value.
    Author:
    Nicolas François
    • Constructor Detail

      • ShouldContainValue

        private ShouldContainValue​(Object actual,
                                   Object value)
      • ShouldContainValue

        private ShouldContainValue​(Object actual,
                                   Condition<?> valueCondition)
    • Method Detail

      • shouldContainValue

        public static ErrorMessageFactory shouldContainValue​(Object actual,
                                                             Object value)
        Creates a new ShouldContainValue.
        Parameters:
        actual - the actual value in the failed assertion.
        value - the value not found
        Returns:
        the created ErrorMessageFactory.
      • shouldContainValue

        public static ErrorMessageFactory shouldContainValue​(Object actual,
                                                             Condition<?> valueCondition)
        Creates a new ShouldContainValue.
        Parameters:
        actual - the actual map in the failed assertion.
        valueCondition - value condition.
        Returns:
        the created ErrorMessageFactory.