public void TestClearRemovesAll() { Document d = new Document(); d["one"] = 1; d.Add("two", 2); d["three"] = 3; Assert.AreEqual(3,d.Count); d.Clear(); Assert.AreEqual(0, d.Count); Assert.IsNull(d["one"]); Assert.IsFalse(d.Contains("one")); }
public void TestClearRemovesAll() { Document d = new Document(); d["one"] = 1; d.Add("two", 2); d["three"] = 3; Assert.AreEqual(3, d.Count); d.Clear(); Assert.AreEqual(0, d.Count); Assert.IsNull(d["one"]); Assert.IsFalse(d.Contains("one")); }