public override bool Matches(object obj)
{
var cmisObj = obj as ICmisObject;
if (cmisObj == null)
{
return Problem("A cmis object", "Something else");
}
foreach (var prop in cmisObj.Properties)
{
if (!prop.LocalName.Equals(_propertyName))
{
continue;
}
if (!prop.Value.Equals(_propertyValue))
{
return Problem("Object with property value {0}", _propertyValue, prop.Value);
}
return true;
}
return Problem("Object with the specified property", "Object without that property");
}
}