public void ControllerManager_GetControllerName_WebpageNotPublishedAndNotAllowedReturnsNull()
        {
            var stubDisallowedWebpage = new StubDisallowedWebpage();

            A.CallTo(() => _userUIPermissionsService.IsCurrentUserAllowed(stubDisallowedWebpage)).Returns(false);
            _controllerManager.GetControllerName(stubDisallowedWebpage, "GET").Should().BeNull();
        }
Esempio n. 2
0
        public void ControllerManager_GetActionName_WebpageNotAllowedAndUnpublishedReturnsNull()
        {
            var stubDisallowedWebpage = new StubDisallowedWebpage();

            A.CallTo(() => _userUIPermissionsService.IsCurrentUserAllowed(stubDisallowedWebpage)).Returns(false);

            _controllerManager.GetActionName(stubDisallowedWebpage, "GET").Should().BeNull();
        }