File tree Expand file tree Collapse file tree
src/Services/Basket/Basket.UnitTests/Application Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -54,7 +54,8 @@ public async Task Get_customer_basket_success()
5454 var actionResult = await basketController . GetBasketByIdAsync ( fakeCustomerId ) ;
5555
5656 //Assert
57- Assert . Equal ( ( ( CustomerBasket ) actionResult . Value ) . BuyerId , fakeCustomerId ) ;
57+ Assert . Equal ( ( actionResult . Result as OkObjectResult ) . StatusCode , ( int ) System . Net . HttpStatusCode . OK ) ;
58+ Assert . Equal ( ( ( ( ObjectResult ) actionResult . Result ) . Value as CustomerBasket ) . BuyerId , fakeCustomerId ) ;
5859 }
5960
6061 [ Fact ]
@@ -79,7 +80,8 @@ public async Task Post_customer_basket_success()
7980 var actionResult = await basketController . UpdateBasketAsync ( fakeCustomerBasket ) ;
8081
8182 //Assert
82- Assert . Equal ( ( ( CustomerBasket ) actionResult . Value ) . BuyerId , fakeCustomerId ) ;
83+ Assert . Equal ( ( actionResult . Result as OkObjectResult ) . StatusCode , ( int ) System . Net . HttpStatusCode . OK ) ;
84+ Assert . Equal ( ( ( ( ObjectResult ) actionResult . Result ) . Value as CustomerBasket ) . BuyerId , fakeCustomerId ) ;
8385 }
8486
8587 [ Fact ]
You can’t perform that action at this time.
0 commit comments