public void GetBook_When_ShopDoesNotExist_ReturnsNotFound() { var request = BookRequestHelper.GetBook("UnexistingShop", EXISTING_BOOK); var response = this.restClient.Execute <BookResponse>(request); Assert.AreEqual(HttpStatusCode.NotFound, response.StatusCode); }
public void GetBook__When_BookDoesntExist_Returns404() { var request = BookRequestHelper.GetBook(shopName, UNEXISTING_BOOK); var response = this.restClient.Execute(request); Assert.AreEqual(HttpStatusCode.NotFound, response.StatusCode); }
public void GetBook_When_BookExists_Returns200() { var request = BookRequestHelper.GetBook(shopName, EXISTING_BOOK); var response = this.restClient.Execute <BookResponse>(request); Assert.AreEqual(HttpStatusCode.OK, response.StatusCode); Assert.NotNull(response.Data); Assert.AreEqual(EXISTING_BOOK, response.Data.ISBN); }