Skip to content

Commit a4e7045

Browse files
author
smgfreeman
committed
corrected mismatch message
1 parent e878329 commit a4e7045

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

hamcrest-core/src/main/java/org/hamcrest/FeatureMatcher.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@ public FeatureMatcher(Matcher<? super U> subMatcher, String featureDescription,
3939
protected boolean matchesSafely(T actual, Description mismatchDescription) {
4040
final U featureValue = featureValueOf(actual);
4141
if (!subMatcher.matches(featureValue)) {
42-
mismatchDescription.appendText(featureName).appendText(" was ");
42+
mismatchDescription.appendText(featureName).appendText(" ");
4343
subMatcher.describeMismatch(featureValue, mismatchDescription);
4444
return false;
4545
}

hamcrest-unit-test/src/main/java/org/hamcrest/FeatureMatcherTest.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ public void testMatchesPartOfAnObject() {
1616
}
1717

1818
public void testMismatchesPartOfAnObject() {
19-
assertMismatchDescription("result was mismatch-description", resultMatcher, new Thingy("foo"));
19+
assertMismatchDescription("result mismatch-description", resultMatcher, new Thingy("foo"));
2020
}
2121

2222
public void testDoesNotThrowNullPointerException() {

0 commit comments

Comments
 (0)