public void ToString_ReturnStringRepresentation() { var diffAttr = new DiffAttribute(DiffAction.Removed, Raw); string result = diffAttr.ToString(); string expected = "- Attribute: \"name\" with value: \"val\"\r\n"; Assert.AreEqual(expected, result); }
public void Visit(DiffAttribute attr, XdtContext param) { param.HandleAttr(attr.Raw.Name, attr.Action); }
public void Visit(DiffAttribute attr, int level) { _sb.AppendFormat("{0}{1} Attribute: \"{2}\" with value: \"{3}\"\r\n", BuildIndent(level), ActionToString(attr.Action), attr.Raw.Name, attr.Raw.Value); }
public void Visit(DiffAttribute attr, int param) { _sb.AppendFormat("<span{0}>\"{1}\"=\"{2}\"</span>", ActionToString(attr.Action), attr.Raw.Name, System.Security.SecurityElement.Escape(attr.Raw.Value)); }
public void IsChangedProperty_ShouldAlwaysBeTrue(DiffAction action) { var diffAttr = new DiffAttribute(action, Raw); Assert.IsTrue(diffAttr.IsChanged); }