Class ShouldContainPattern

  • All Implemented Interfaces:
    ErrorMessageFactory

    public class ShouldContainPattern
    extends BasicErrorMessageFactory
    Creates an error message indicating that an assertion that verifies that a CharSequence contains a pattern failed.
    • Constructor Detail

      • ShouldContainPattern

        private ShouldContainPattern​(java.lang.CharSequence actual,
                                     java.lang.CharSequence pattern)
    • Method Detail

      • shouldContainPattern

        public static ErrorMessageFactory shouldContainPattern​(java.lang.CharSequence actual,
                                                               java.lang.CharSequence pattern)
        Creates a new ShouldContainPattern.
        Parameters:
        actual - the actual value in the failed assertion.
        pattern - a regular expression pattern.
        Returns:
        the created ErrorMessageFactory.