Package de.bmiag.tapir.util.extensions
Class IsEqualIgnoringLinebreakStyleMatcher
- java.lang.Object
-
- org.hamcrest.BaseMatcher<T>
-
- org.hamcrest.TypeSafeMatcher<java.lang.String>
-
- de.bmiag.tapir.util.extensions.IsEqualIgnoringLinebreakStyleMatcher
-
- All Implemented Interfaces:
org.hamcrest.Matcher<java.lang.String>
,org.hamcrest.SelfDescribing
public class IsEqualIgnoringLinebreakStyleMatcher extends org.hamcrest.TypeSafeMatcher<java.lang.String>
Matcher which ignores \r\n differences.- Author:
- Oliver Libutzki <[email protected]>
-
-
Constructor Summary
Constructors Constructor Description IsEqualIgnoringLinebreakStyleMatcher(java.lang.String string)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description void
describeMismatchSafely(java.lang.String item, org.hamcrest.Description mismatchDescription)
void
describeTo(org.hamcrest.Description description)
static org.hamcrest.Matcher<java.lang.String>
isEqualIgnoringLinebreakStyle(java.lang.String expectedString)
boolean
matchesSafely(java.lang.String item)
java.lang.String
stripSpace(java.lang.String toBeStripped)
-
-
-
Method Detail
-
matchesSafely
public boolean matchesSafely(java.lang.String item)
- Specified by:
matchesSafely
in classorg.hamcrest.TypeSafeMatcher<java.lang.String>
-
describeMismatchSafely
public void describeMismatchSafely(java.lang.String item, org.hamcrest.Description mismatchDescription)
- Overrides:
describeMismatchSafely
in classorg.hamcrest.TypeSafeMatcher<java.lang.String>
-
describeTo
public void describeTo(org.hamcrest.Description description)
-
stripSpace
public java.lang.String stripSpace(java.lang.String toBeStripped)
- Parameters:
toBeStripped
- the string to be stripped- Returns:
- the stripped string
-
isEqualIgnoringLinebreakStyle
public static org.hamcrest.Matcher<java.lang.String> isEqualIgnoringLinebreakStyle(java.lang.String expectedString)
- Parameters:
expectedString
- the expected string- Returns:
- the matcher
-
-