public void GetDamageReportsRepairedByUserTest() { DamageReport dr = DamageReportFactory.NewDamageReport(); (string token, int userId)queryParams = UsingDbContext(context => DamageReportsMockDatabaseHelper.AddRepairedDamageReport(dr, context)); List <DamageReportOutputDto> queryResult = _damageReportAppService.GetReportsRepairedByUser(queryParams.token, queryParams.userId); Assert.Equal(dr.Description, queryResult.First().Description); }
public List <DamageReportOutputDto> GetDamageReportsRepairedByUser(int id) { string token = Utillities.GetTokenFromRequest(Request); return(_damageAppService.GetReportsRepairedByUser(token, id)); }