public async Task GetColorNotFoundResult(ICollection <CarBrand> brands) { // Arrange var query = new CarContextQueryMockBuilder().SetCarBrands(brands).CarsContextQuery; var controller = new CarBrandsQueryController(query); // Act IHttpActionResult result = await controller.GetBrand(0); // Assert result.Should().BeOfType <NotFoundResult>(); }
public async Task GetColorOkResult(ICollection <CarBrand> brands) { // Arrange var query = new CarContextQueryMockBuilder().SetCarBrands(brands).CarsContextQuery;; var controller = new CarBrandsQueryController(query); // Act IHttpActionResult result = await controller.GetBrand(1); // Assert result.Should().BeOfType <OkNegotiatedContentResult <BrandReadModel> >(); }