public Faq?GetPublishedFaqByIdForTargetGroup(int faqId, int targetGroup)
        {
            var faq = faqsDataService.GetFaqById(faqId);

            if (faq?.Published == true && faq?.TargetGroup == targetGroup)
            {
                return(faq);
            }

            return(null);
        }
        public void GetPublishedFaqByIdForTargetGroup_returns_expected_faq_from_data_service()
        {
            // Given
            const int expectedFaqId       = 1;
            const int expectedTargetGroup = 0;
            var       expectedFaq         = Builder <Faq> .CreateNew().With(f => f.Published = true).And(f => f.TargetGroup = 0)
                                            .Build();

            A.CallTo(() => faqDataService.GetFaqById(expectedFaqId))
            .Returns(expectedFaq);

            // When
            var result = faqsService.GetPublishedFaqByIdForTargetGroup(expectedFaqId, expectedTargetGroup);

            // Then
            using (new AssertionScope())
            {
                result.Should().BeEquivalentTo(expectedFaq);

                A.CallTo(() => faqDataService.GetFaqById(expectedFaqId))
                .MustHaveHappenedOnceExactly();
            }
        }