private void InitializeValueList() { _valueListAttribute = ValueListAttribute.GetAttribute(_target); if (IsValueListDefined) { _valueList = ValueListAttribute.GetReference(_target); } }
public void GetGenericListOfStringInterfaceReference() { var options = new MockOptions(); IList <string> values = ValueListAttribute.GetReference(options); Assert.IsNotNull(values); Assert.AreEqual(typeof(List <string>), values.GetType()); }
public void Get_generic_list_of_string_interface_reference() { var options = new MockOptions(); IList <string> values = ValueListAttribute.GetReference(options); values.Should().NotBeNull(); values.GetType().Should().Be(typeof(List <string>)); }
public void Use_generic_list_of_string_interface_reference() { var options = new MockOptions(); var values = ValueListAttribute.GetReference(options); values.Add("value0"); values.Add("value1"); values.Add("value2"); base.ElementsShouldBeEqual(new string[] { "value0", "value1", "value2" }, options.Values); }
public void UseGenericListOfStringInterfaceReference() { MockOptions options = new MockOptions(); IList <string> values = ValueListAttribute.GetReference(options); values.Add("value0"); values.Add("value1"); values.Add("value2"); Assert.AreEqual("value0", options.Values[0]); Assert.AreEqual("value1", options.Values[1]); Assert.AreEqual("value2", options.Values[2]); }
public void UseGenericListOfStringInterfaceReference() { var options = new MockOptions(); var values = ValueListAttribute.GetReference(options); values.Add("value0"); values.Add("value1"); values.Add("value2"); //Assert.AreEqual("value0", options.Values[0]); //Assert.AreEqual("value1", options.Values[1]); //Assert.AreEqual("value2", options.Values[2]); base.AssertArrayItemEqual(new string[] { "value0", "value1", "value2" }, options.Values); }