in src/main/java/org/apache/sling/hamcrest/matchers/ResourcePropertiesMatcher.java [95:106]
protected void describeMismatchSafely(Resource item, Description mismatchDescription) {
Map<String, Object> actualProperties = item.adaptTo(ValueMap.class);
if (actualProperties == null) {
mismatchDescription.appendText("was Resource which does not expose a value map via adaptTo(ValueMap.class)");
return;
}
mismatchDescription.appendText("was Resource with properties ")
.appendValueList("[", ",", "]", convertArraysToStrings(actualProperties).entrySet())
.appendText(" (resource: ")
.appendValue(item)
.appendText(")");
}