public void CanRemoveElementCustomNodeByNameWithSingleCategory() { var model = new SearchViewModel(); model.Add("Peter", "Greens", "A description", System.Guid.NewGuid()); model.SearchAndUpdateResultsSync("Peter"); Assert.AreEqual(1, model.SearchResults.Count); model.Remove("Peter"); model.SearchAndUpdateResultsSync("Peter"); Assert.AreEqual(0, model.SearchResults.Count); }
public void CanTryToRemoveElementFromSearchWithNonexistentName() { var model = new SearchViewModel(); model.Remove("NonExistentName"); model.SearchAndUpdateResultsSync("NonExistentName"); Assert.AreEqual(0, model.SearchResults.Count); }