public async Task Browse_ReturnsListOfHairStyles() { // Arrange _hairStylesContext = _db.SeedHairStylesContext(); List <HairStyles> expected = _db.HairStyles; // Act List <HairStyles> actual = await _hairStylesContext.Browse(); // Assert Assert.Equal(expected.Count, actual.Count); }
public async Task Browse_Limit_Offset_Search_ReturnsFilteredHairStyles() { // Arrange _hairStylesContext = _db.SeedHairStylesContext(); List <HairStyles> expected = _db.HairStyles.FindAll(hs => hs.HairStyleName == "bob"); // Act // Equivalent to GET /hair_styles?limit=1000&offset=0&search=bob List <HairStyles> actual = await _hairStylesContext.Browse("1000", "0", "bob"); // Assert Assert.Equal(expected.Count, actual.Count); }