System.Tests.GetCustomAttribute.NegTest6 C# (CSharp) Method

NegTest6() private method

private NegTest6 ( ) : void
return void
        public static void NegTest6()
        {
            ParameterInfo element = null;
            Type attributeType = typeof(DebuggableAttribute);
            Type clsType = typeof(DerivedClass);

            Assert.Throws<ArgumentNullException>(() => (DebuggableAttribute)Attribute.GetCustomAttribute(element, attributeType, false));
            attributeType = null;
            Assert.Throws<ArgumentNullException>(() => (DebuggableAttribute)Attribute.GetCustomAttribute(clsType.Module, attributeType, false));
            attributeType = typeof(object);
            Assert.Throws<ArgumentException>(() => (DebuggableAttribute)Attribute.GetCustomAttribute(clsType.Module, attributeType, false));

        }
        [Fact]