public void Contains() { var d = new DObject(); d.Contains("key").ShouldBeFalse(); d["key"] = "value"; d.Contains("key").ShouldBeTrue(); }
public void Remove() { var d = new DObject { ["key1"] = "value" }; d.Rename("key1", "key2"); d.Contains("key1").ShouldBeFalse(); d.Contains("key2").ShouldBeTrue(); Should.Throw <KeyNotFoundException>(() => d.Rename("key1", "key2")); }
public void Rename() { var d = new DObject { ["key"] = "value" }; d.Remove("key"); d.Contains("key").ShouldBeFalse(); }
public void Clear() { var d = new DObject { ["key"] = "value" }; d.Clear(); d.Contains("key").ShouldBeFalse(); }