public void GetNewsItems_WithValidNewsRootAndNewsItems_ReturnsNewsItems() { // Arrange var newsItemService = new NewsItemService(); using (var db = FakeDbFactory.CreateDbWithNewsRootAndWithNewsItems()) { // Act var result = newsItemService.GetNewsItems(); // Assert result.Should().NotBeEmpty(); } }
public void GetNewsItems_WithInvalidNewsRoot_ReturnsEmptyList() { // Arrange var newsItemService = new NewsItemService(); using (var db = FakeDbFactory.CreateDbWithoutNewsRoot()) { // Act var result = newsItemService.GetNewsItems(); // Assert result.Should().BeEmpty(); } }