public void op_GetEnumerator() { IEnumerable obj = new MultitonCollection <int, DateTime>(); Assert.NotNull(obj.GetEnumerator()); Assert.NotNull(new MultitonCollection <int, DateTime>().GetEnumerator()); }
public void op_Add_TKey_TValue() { var obj = new MultitonCollection <int, DateTime>(); Assert.Equal(0, obj.Count()); obj.Add(123, DateTime.Today); Assert.Equal(1, obj.Count()); }
public void indexer_TKey_getAdd() { var expected = DateTime.MinValue; var obj = new MultitonCollection <int, DateTime>(); var actual = obj[123]; Assert.Equal(expected, actual); }
public void op_GetValue_TKey() { var obj = new MultitonCollection <int, string>(); const string expected = "example"; obj.Add(123, expected); Assert.Equal(expected, obj.GetValue(123)); }
public void op_ContainsKey_TKey() { var obj = new MultitonCollection <int, DateTime> { { 123, DateTime.Today } }; Assert.True(obj.ContainsKey(123)); }
public void indexer_TKey_setAdd() { const string expected = "example"; var obj = new MultitonCollection <int, string>(); obj[123] = expected; var actual = obj[123]; Assert.Equal(expected, actual); }
public void indexer_TKey_get() { const string expected = "example"; var obj = new MultitonCollection <int, string> { { 123, expected } }; var actual = obj[123]; Assert.Equal(expected, actual); }