public void GetAllClientsTest() { var clients = _clientsService.GetAllAsync().Result; Assert.IsNotNull(clients); Assert.AreEqual(clients.Count, _clients.ToList().Count); }
public IHttpActionResult GetAll() { try { return(Ok(_clientService.GetAllAsync().Result)); } catch (Exception ex) { return(InternalServerError(ex)); } }
/// <summary> /// Get a list of items /// </summary> /// <returns>List with TodoModels</returns> public virtual async Task <IEnumerable <ClientsModel> > GetAllClients() { return(await _clientService.GetAllAsync()); }
public async Task <IActionResult> GetAll() { var models = await _clientsService.GetAllAsync(); return(Ok(models)); }