Example #1
0
        public static void Validate_InvalidEnumType_ThrowsInvalidOperationException(Type enumType)
        {
            var attribute = new EnumDataTypeAttribute(enumType);

            Assert.Throws <InvalidOperationException>(() => attribute.Validate("AnyValue", new ValidationContext(new object())));
        }
 public static void Validate_InvalidEnumType_ThrowsInvalidOperationException(Type enumType)
 {
     var attribute = new EnumDataTypeAttribute(enumType);
     Assert.Throws<InvalidOperationException>(() => attribute.Validate("AnyValue", new ValidationContext(new object())));
 }