public async Task PrivacyPolicy_ReturnsCorrectViewWhenOrgHasAPolicyDefined()
        {
            var modelWithPolicy = new OrganizationPrivacyPolicyViewModel { OrganizationName = "Org 2", Content = "A privacy policy" };

            OrganizationController controller;
            MockMediatorOrganizationPrivacyPolicyQuery(out controller, modelWithPolicy);

            var result = await controller.OrganizationPrivacyPolicy(2) as ViewResult;

            Assert.NotNull(result);
            Assert.Equal("OrgPrivacyPolicy", result.ViewName);
        }
        private static void MockMediatorOrganizationPrivacyPolicyQuery(out OrganizationController controller, OrganizationPrivacyPolicyViewModel model = null)
        {
            if (model == null) model = new OrganizationPrivacyPolicyViewModel { OrganizationName = "Org 1", Content = null };

            var mockMediator = new Mock<IMediator>();
            mockMediator.Setup(mock => mock.SendAsync(It.IsAny<OrganziationPrivacyPolicyQueryAsync>())).Returns(() => Task.FromResult(model)).Verifiable();
            controller = new OrganizationController(mockMediator.Object);
        }