Exemple #1
0
        public void IsValidForEnum_FlagsArray()
        {
            bool isArray;
            bool isNullable;
            Type enumType;

            var isValid = HtmlExtensions.IsValidForEnum(typeof(MyFlagsEnum[]), out isArray, out isNullable, out enumType);

            Assert.IsFalse(isValid);
        }
Exemple #2
0
        public void IsValidForEnum_Default()
        {
            bool isArray;
            bool isNullable;
            Type enumType;

            var isValid = HtmlExtensions.IsValidForEnum(typeof(MyEnum), out isArray, out isNullable, out enumType);

            Assert.IsTrue(isValid);
            Assert.IsFalse(isArray);
            Assert.IsFalse(isNullable);
            Assert.AreEqual(typeof(MyEnum), enumType);
        }