public async Task PesquisarHistoricoPedidos_HistoricoPedidoCliente_DeveRetornarHistoricoComSucesso() { //Arrange var clienteId = 1; //Act var historico = await _querie.FindAsyncByClienteId(clienteId); //Assert Assert.True(historico.Count() > 0); }
public async Task <IActionResult> GetById(long id) { try { var result = await _querie.FindAsyncByClienteId(id); return(Ok(new ResultCommand(result, Infrastructure.Shared.Constants.StatusCode.IsSuccess))); } catch (Exception err) { return(BadRequest(new ResultCommand(err.Message, Infrastructure.Shared.Constants.StatusCode.Invalid))); } }