public class StringEndsWith extends SubstringMatcher
substring| Constructor and Description |
|---|
StringEndsWith(String substring) |
| Modifier and Type | Method and Description |
|---|---|
static Matcher<String> |
endsWith(String suffix)
|
protected boolean |
evalSubstringOf(String s) |
protected String |
relationship() |
describeMismatchSafely, describeTo, matchesSafelydescribeMismatch, matches_dont_implement_Matcher___instead_extend_BaseMatcher_, toStringpublic StringEndsWith(String substring)
protected boolean evalSubstringOf(String s)
evalSubstringOf in class SubstringMatcherprotected String relationship()
relationship in class SubstringMatcherpublic static Matcher<String> endsWith(String suffix)
String ends with the specified
String.
For example:
assertThat("myStringOfNote", endsWith("Note"))suffix - the substring that the returned matcher will expect at the end of any examined stringCopyright © 2002–2017 JUnit. All rights reserved.