public void SetDetail_ToBoolean_WithSameValueAsDefault_DoesntAddDetail_True() { AnItem item = new AnItem(); item.SetDetailAccessor("ADetail", true, true); Assert.That(item.Details.ContainsKey("ADetail"), Is.False); }
public void SetDetail_WithBoolean_AddsDetail() { AnItem item = new AnItem(); item.SetDetailAccessor("ADetail", false); Assert.That(item.Details["ADetail"], Is.Not.Null); }
public void SetDetail_ToString_WithSameValueAsDefault_DoesntAddDetail() { AnItem item = new AnItem(); item.SetDetailAccessor("ADetail", "howdy", "howdy"); Assert.That(item.Details.ContainsKey("ADetail"), Is.False); }
public void SetDetail_ToString_WithDefault_AddsStringDetail_WithSameValue() { AnItem item = new AnItem(); item.SetDetailAccessor("ADetail", "hello", "howdy"); Assert.That(item.Details["ADetail"].Value, Is.EqualTo("hello")); }
public void SetDetail_ToString_WithDefault_AddsDetail() { AnItem item = new AnItem(); item.SetDetailAccessor("ADetail", "hello", "howdy"); Assert.That(item.Details["ADetail"], Is.Not.Null); }
public void SetDetail_ToBoolean_AddsBooleanDetail() { AnItem item = new AnItem(); item.SetDetailAccessor("ADetail", false); Assert.That(item.Details["ADetail"].ValueType, Is.EqualTo(typeof(bool))); Assert.That(item.Details["ADetail"].ValueTypeKey, Is.EqualTo(ContentDetail.TypeKeys.BoolType)); }
public void SetDetail_ToString_AddsStringDetail() { AnItem item = new AnItem(); item.SetDetailAccessor("ADetail", "hello"); Assert.That(item.Details["ADetail"].ValueType, Is.EqualTo(typeof(string))); Assert.That(item.Details["ADetail"].ValueTypeKey, Is.EqualTo(ContentDetail.TypeKeys.StringType)); }