public async Task AdicionarItem_NovoPedido_DeveRetornarComSucesso() { // Arrange var itemInfo = new ItemViewModel { Id = new Guid("22043EE5-985C-44BE-9077-08D78CD4B3AF"), Quantidade = 2 }; await _testsFixture.RealizarLoginApi(); _testsFixture.Client.AtribuirToken(_testsFixture.UsuarioToken); // Act var postResponse = await _testsFixture.Client.PostAsJsonAsync("api/carrinho", itemInfo); // Assert postResponse.EnsureSuccessStatusCode(); }
public async Task AdicionarItem_NovoPedido_DeveRetornarComSucesso() { // Arrange var itemInfo = new ItemViewModel { Id = new Guid("11BDDD3E-ACD4-4C3B-AE74-8E473993C5DD"), Quantidade = 2 }; await _testsFixture.RealizarLoginApi(); _testsFixture.Client.AtribuirToken(_testsFixture.UsuarioToken); // Acts var postResponse = await _testsFixture.Client.PostAsJsonAsync("api/carrinho", itemInfo); // Assert postResponse.EnsureSuccessStatusCode(); }
public async Task AdicionarItem_NovoPedido_DeveRetornarComSucesso() { //Arrange var itemInfo = new ItemViewModel { Id = new Guid("191ddd3e-acd4-4c3b-ae74-8e473993c5da"), Quantidade = 2 }; await testsFixture.RealizarLoginApi(); testsFixture.Client.AtribuirToken(testsFixture.UsuarioToken); //Act var postResponse = await testsFixture.Client.PostAsJsonAsync("api/carrinho", itemInfo); //assert postResponse.EnsureSuccessStatusCode(); }
public async Task AdicionarItem_NovoPedido_DeveRetornarComSucesso() { // Arrange var itemInfo = new ItemViewModel { Id = new Guid("4251ebd0-0e7e-4169-8ea6-50588d6f1714"), Quantidade = 2 }; await _testsFixture.RealizarLoginApi(); _testsFixture.Client.AtribuirToken(_testsFixture.UsuarioToken); // Act var postResponse = await _testsFixture.Client.PostAsJsonAsync("api/carrinho", itemInfo); // Assert postResponse.EnsureSuccessStatusCode(); }