Пример #1
0
        public void HasAuthenticateAttributeReturnsFalse()
        {
            var descriptor = new ControllerActionDescriptor
            {
                MethodInfo = GetMethodInfo <ExecutionFilterTest>(x => x.TestControllerWithoutAuthenticateAttribute())
            };

            var result = ExecutionFilterAttribute.HasAuthenticateAttribute(descriptor);

            Assert.IsFalse(result);
        }
Пример #2
0
        public void HasAuthenticateAttributeDescriptorIsNull()
        {
            var result = ExecutionFilterAttribute.HasAuthenticateAttribute(null);

            Assert.IsFalse(result);
        }
Пример #3
0
        public void HasAuthenticateAttributeMethodIsNull()
        {
            var result = ExecutionFilterAttribute.HasAuthenticateAttribute(new ControllerActionDescriptor());

            Assert.IsFalse(result);
        }