public void SearchImages_SearchTextNull_ThrowsArgumentNullException2() { int count = 2; var logic = new ImageLogic(new DummyImageManager(count)); Assert.ThrowsException <ArgumentNullException>(() => logic.SearchImages(null)); }
public void SearchImages_ValidSearchText_ReturnsCorrectResult(string searchText, int expectedResults) { int count = 20; var logic = new ImageLogic(new DummyImageManager(count)); var images = logic.SearchImages(searchText); Assert.AreEqual(expectedResults, images.Count()); }
public void SearchImages_SearchTextEmpty_ReturnsAllImages() { int count = 2; var logic = new ImageLogic(new DummyImageManager(count)); var images = logic.SearchImages(string.Empty); Assert.AreEqual(count, images.Count()); }
public void SearchImages_SearchTextNull_ThrowsArgumentNullException() { var logic = new ImageLogic(new DummyImageManager(2)); logic.SearchImages(null); }