public async Task PagesControllerSideBarRightJsonReturnsSuccess(string mediaTypeName)
        {
            // Arrange
            var dummyJobGroupModel    = A.Dummy <JobGroupModel>();
            var dummyContentItemModel = A.Dummy <ContentItemModel>();
            var controller            = BuildPagesController(mediaTypeName);
            var socRequestModel       = new SocRequestModel {
                Soc = 3231, FromJobProfileCanonicalName = "a-job-profile",
            };
            var dummySideBarRightViewModel = A.Dummy <SideBarRightViewModel>();

            dummySideBarRightViewModel.JobProfiles = new List <JobProfileViewModel> {
                new JobProfileViewModel {
                    CanonicalName = socRequestModel.FromJobProfileCanonicalName, Title = "A title"
                },
            };

            A.CallTo(() => FakeJobGroupDocumentService.GetAsync(A <Expression <Func <JobGroupModel, bool> > > .Ignored, A <string> .Ignored)).Returns(dummyJobGroupModel);
            A.CallTo(() => FakeMapper.Map <SideBarRightViewModel>(A <JobGroupModel> .Ignored)).Returns(dummySideBarRightViewModel);
            A.CallTo(() => FakeSharedContentDocumentService.GetByIdAsync(A <Guid> .Ignored, A <string> .Ignored)).Returns(dummyContentItemModel);

            // Act
            var result = await controller.SideBarRight(socRequestModel).ConfigureAwait(false);

            // Assert
            A.CallTo(() => FakeJobGroupDocumentService.GetAsync(A <Expression <Func <JobGroupModel, bool> > > .Ignored, A <string> .Ignored)).MustHaveHappenedOnceExactly();
            A.CallTo(() => FakeMapper.Map <SideBarRightViewModel>(A <JobGroupModel> .Ignored)).MustHaveHappenedOnceExactly();
            A.CallTo(() => FakeSharedContentDocumentService.GetByIdAsync(A <Guid> .Ignored, A <string> .Ignored)).MustHaveHappenedOnceExactly();

            var jsonResult = Assert.IsType <OkObjectResult>(result);

            _ = Assert.IsAssignableFrom <SideBarRightViewModel>(jsonResult.Value);

            controller.Dispose();
        }
        public async Task PagesControllerSideBarRightReturnsNotAcceptable(string mediaTypeName)
        {
            // Arrange
            var dummyJobGroupModel    = A.Dummy <JobGroupModel>();
            var dummyContentItemModel = A.Dummy <ContentItemModel>();
            var controller            = BuildPagesController(mediaTypeName);
            var socRequestModel       = new SocRequestModel {
                Soc = 3231, FromJobProfileCanonicalName = "a-job-profile",
            };
            var dummySideBarRightViewModel = A.Dummy <SideBarRightViewModel>();

            A.CallTo(() => FakeJobGroupDocumentService.GetAsync(A <Expression <Func <JobGroupModel, bool> > > .Ignored, A <string> .Ignored)).Returns(dummyJobGroupModel);
            A.CallTo(() => FakeMapper.Map <SideBarRightViewModel>(A <JobGroupModel> .Ignored)).Returns(dummySideBarRightViewModel);
            A.CallTo(() => FakeSharedContentDocumentService.GetByIdAsync(A <Guid> .Ignored, A <string> .Ignored)).Returns(dummyContentItemModel);

            // Act
            var result = await controller.SideBarRight(socRequestModel).ConfigureAwait(false);

            // Assert
            A.CallTo(() => FakeJobGroupDocumentService.GetAsync(A <Expression <Func <JobGroupModel, bool> > > .Ignored, A <string> .Ignored)).MustHaveHappenedOnceExactly();
            A.CallTo(() => FakeMapper.Map <SideBarRightViewModel>(A <JobGroupModel> .Ignored)).MustHaveHappenedOnceExactly();
            A.CallTo(() => FakeSharedContentDocumentService.GetByIdAsync(A <Guid> .Ignored, A <string> .Ignored)).MustHaveHappenedOnceExactly();

            var statusResult = Assert.IsType <StatusCodeResult>(result);

            A.Equals((int)HttpStatusCode.NotAcceptable, statusResult.StatusCode);

            controller.Dispose();
        }