public void Properties() { Poker p1 = new Poker(); Poker p2 = new Poker(); Assert.AreEqual(false, p1.GetProperties().Contains("myProperty"), "Contains myProperty"); Assert.AreEqual(false, p1.GetProperties() == p2.GetProperties(), "#"); }
public void Properties () { Poker p1 = new Poker (); Poker p2 = new Poker (); Assert.AreEqual (false, p1.GetProperties ().Contains ("myProperty"), "Contains myProperty"); Assert.AreEqual (false, p1.GetProperties () == p2.GetProperties (), "#"); }
// [NUnit.Framework.Category("NotWorking")] public void Properties() { Poker p = new Poker("name", "value"); ConfigurationPropertyCollection props = p.GetProperties(); Assert.NotNull(props); Assert.Equal(2, props.Count); ConfigurationProperty prop; prop = props["key"]; Assert.Equal("key", prop.Name); Assert.Null(prop.Description); Assert.Equal(typeof(string), prop.Type); Assert.Equal(typeof(StringConverter), prop.Converter.GetType()); Assert.NotNull(prop.Validator); Assert.Equal(typeof(DefaultValidator), prop.Validator.GetType()); Assert.Equal("", prop.DefaultValue); Assert.True(prop.IsKey, "A9"); Assert.True(prop.IsRequired, "A10"); Assert.False(prop.IsDefaultCollection, "A11"); prop = props["value"]; Assert.Equal("value", prop.Name); Assert.Null(prop.Description); Assert.Equal(typeof(string), prop.Type); Assert.Equal(typeof(StringConverter), prop.Converter.GetType()); Assert.Equal(typeof(DefaultValidator), prop.Validator.GetType()); Assert.Equal("", prop.DefaultValue); Assert.False(prop.IsKey, "A18"); Assert.False(prop.IsRequired, "A19"); Assert.False(prop.IsDefaultCollection, "A20"); }
public void Properties() { Poker p = new Poker("name", "value"); ConfigurationPropertyCollection props = p.GetProperties(); Assert.IsNotNull(props, "A1"); Assert.AreEqual(2, props.Count, "A2"); ConfigurationProperty prop; prop = props["key"]; Assert.AreEqual("key", prop.Name, "A3"); Assert.IsNull(prop.Description, "A4"); Assert.AreEqual(typeof(string), prop.Type, "A5"); Assert.AreEqual(typeof(StringConverter), prop.Converter.GetType(), "A6"); Assert.IsNotNull(prop.Validator, "Anull"); Assert.AreEqual(typeof(DefaultValidator), prop.Validator.GetType(), "A7"); Assert.AreEqual("", prop.DefaultValue, "A8"); Assert.IsTrue(prop.IsKey, "A9"); Assert.IsTrue(prop.IsRequired, "A10"); Assert.IsFalse(prop.IsDefaultCollection, "A11"); prop = props["value"]; Assert.AreEqual("value", prop.Name, "A12"); Assert.IsNull(prop.Description, "A13"); Assert.AreEqual(typeof(string), prop.Type, "A14"); Assert.AreEqual(typeof(StringConverter), prop.Converter.GetType(), "A15"); Assert.AreEqual(typeof(DefaultValidator), prop.Validator.GetType(), "A16"); Assert.AreEqual("", prop.DefaultValue, "A17"); Assert.IsFalse(prop.IsKey, "A18"); Assert.IsFalse(prop.IsRequired, "A19"); Assert.IsFalse(prop.IsDefaultCollection, "A20"); }
public void Properties () { Poker p = new Poker ("name", "value"); ConfigurationPropertyCollection props = p.GetProperties(); Assert.IsNotNull (props, "A1"); Assert.AreEqual (2, props.Count, "A2"); ConfigurationProperty prop; prop = props["key"]; Assert.AreEqual ("key", prop.Name, "A3"); Assert.IsNull (prop.Description, "A4"); Assert.AreEqual (typeof (string), prop.Type, "A5"); Assert.AreEqual (typeof (StringConverter), prop.Converter.GetType(), "A6"); Assert.IsNotNull (prop.Validator, "Anull"); Assert.AreEqual (typeof (DefaultValidator), prop.Validator.GetType(), "A7"); Assert.AreEqual ("", prop.DefaultValue, "A8"); Assert.IsTrue (prop.IsKey, "A9"); Assert.IsTrue (prop.IsRequired, "A10"); Assert.IsFalse (prop.IsDefaultCollection, "A11"); prop = props["value"]; Assert.AreEqual ("value", prop.Name, "A12"); Assert.IsNull (prop.Description, "A13"); Assert.AreEqual (typeof (string), prop.Type, "A14"); Assert.AreEqual (typeof (StringConverter), prop.Converter.GetType(), "A15"); Assert.AreEqual (typeof (DefaultValidator), prop.Validator.GetType(), "A16"); Assert.AreEqual ("", prop.DefaultValue, "A17"); Assert.IsFalse (prop.IsKey, "A18"); Assert.IsFalse (prop.IsRequired, "A19"); Assert.IsFalse (prop.IsDefaultCollection, "A20"); }
public void Properties() { Poker p = new Poker(); ConfigurationPropertyCollection props = p.GetProperties(); Assert.IsNotNull(props, "A1"); Assert.AreEqual(0, props.Count, "A2"); }
public void Properties() { Poker p = new Poker(); ConfigurationPropertyCollection props = p.GetProperties(); Assert.NotNull(props); Assert.Equal(0, props.Count); }
public void Properties() { Poker poker = new Poker(); ConfigurationPropertyCollection coll = poker.GetProperties(); Assert.AreEqual(1, coll.Count, "Count"); foreach (ConfigurationProperty prop in coll) { Assert.AreEqual("", prop.Name); } }
public void Properties () { Poker p = new Poker (); ConfigurationPropertyCollection props = p.GetProperties(); Assert.IsNotNull (props, "A1"); Assert.AreEqual (0, props.Count, "A2"); }