public void AllDrinksContainsAllAddedItems() { var expected = new Drink[] { new LocalDrink( "1", "", new Ingredient[ 0 ] ), new LocalDrink( "2", "", new Ingredient[ 0 ] ) }; recipes.Add( expected ); var results = recipes.AllDrinks; Assert.IsTrue( expected.SequenceEqual( results ) ); }
public void FilteredDrinksContainsAllThoseWithSpecifiedIngredients() { var expected = new Drink[] { new LocalDrink( "1", "", new[] { new Ingredient( "a", Measurement.Tsp, 1 ) } ), new LocalDrink( "2", "", new[] { new Ingredient( "a", Measurement.Tsp, 1 ) } ) }; recipes.Add( expected ); var results = recipes.WithIngredients( "a" ); Assert.IsTrue( expected.SequenceEqual( results ) ); }