public void SetAttribute_WithValidNewKeyAndValue_ShouldAddKeyValueToAttributes() { var node = new TagNode(_tagName); node.SetAttribute(_classKey, _classValue); Assert.AreEqual(_classValue, node.GetAttribute(_classKey)); }
public void SetAttribute_WithNullKey_ShouldThrowArgumentException() { var node = new TagNode(_tagName); node.SetAttribute(null, _classValue); }
public void SetAttribute_WithValidKeyAndValue_ShouldAddValueToCurrenetAttribute() { const string value2 = "second"; var node = new TagNode(_tagName); node.SetAttribute(_classKey, _classValue); node.SetAttribute(_classKey, value2); Assert.AreEqual(value2, node.GetAttribute(_classKey)); }
public void SetAttribute_WithEmptyStringKey_ShouldThrowArgumentException() { var node = new TagNode(_tagName); node.SetAttribute(string.Empty, _classValue); }