public async Task GetDatFromApiReturnsListOfUsersIfComponentSettingsisEmpty() { _dataLoader.AddSettings(""); var result = await _dataLoader.GetDataFromApiAsync(); Assert.NotNull(result); Assert.IsType <List <User> >(result); Assert.Equal(_expectedCount, result.Count); Assert.Null(result.First().Phone); Assert.Null(result.First().City); Assert.Null(result.First().Street); Assert.Null(result.First().Email); Assert.Null(result.First().Gender); }
public async Task <object> Get(DataSourceLoadOptions loadOptions) { var data = await _dataLoader.GetDataFromApiAsync(); return(Ok(DataSourceLoader.Load(data, loadOptions))); }