public async Task <List <TestResultResource> > GetTestResults([FromQuery] long testRunId, [FromQuery] long testModuleId = -1) { var testResults = (testModuleId > -1) ? await _repository.GetAll(testRunId) : await _repository.GetAll(testRunId, testModuleId); return(_mapper.Map <List <TestResult>, List <TestResultResource> >(testResults)); }
/// <summary> /// Gets all TestResults. /// </summary> /// <returns> IEnumerable`1 of test results.</returns> public IEnumerable <BllTestResult> GetAllTestResults() { return(repository.GetAll().Select(u => u.ToBllTestResult())); }
public async Task <List <TestResultResource> > GetTestResults([FromQuery] long testRunId) { var testResults = await _repository.GetAll(testRunId); return(_mapper.Map <List <TestResult>, List <TestResultResource> >(testResults)); }