/** * Creates a matcher of {@link String} that matches when the examined string is equal to * the specified expectedString, when whitespace differences are (mostly) ignored. To be * exact, the following whitespace rules are applied: * <ul> * <li>all leading and trailing whitespace of both the expectedString and the examined string are ignored</li> * <li>any remaining whitespace, appearing within either string, is collapsed to a single space before comparison</li> * </ul> * For example: * <pre>assertThat(" my\tfoo bar ", equalToIgnoringWhiteSpace(" my foo bar"))</pre> * * @param expectedString * the expected value of matched strings */ public static Matcher<java.lang.String> equalToCompressingWhiteSpace(java.lang.String expectedString) { return IsEqualCompressingWhiteSpace.equalToCompressingWhiteSpace(expectedString); }
/** * Creates a matcher of {@link String} that matches when the examined string is equal to * the specified expectedString, when whitespace differences are (mostly) ignored. To be * exact, the following whitespace rules are applied: * <ul> * <li>all leading and trailing whitespace of both the expectedString and the examined string are ignored</li> * <li>any remaining whitespace, appearing within either string, is collapsed to a single space before comparison</li> * </ul> * For example: * <pre>assertThat(" my\tfoo bar ", equalToIgnoringWhiteSpace(" my foo bar"))</pre> * * @param expectedString * the expected value of matched strings */ public static Matcher<java.lang.String> equalToCompressingWhiteSpace(java.lang.String expectedString) { return IsEqualCompressingWhiteSpace.equalToCompressingWhiteSpace(expectedString); }