how to make sonarqube mark these lines as covered using unity test

48 Views Asked by At

Sonarqube is asking me to cover the include lines:

var krs = _kRRepository.SelectAllFor(predicate: kr => objectivesIds.Contains(kr.ObjectiveId),
    includes: x => x.Include(kr => kr.KRValues)
    .Include(x => x.KRProgress)
    .Include(x => x.EmployeeKRs)                                                                                
       .ThenInclude(x => x.Employee)
       .ThenInclude(x => x.EmployeeAreas.Where(ea => ea.Area.ManagementCycleId == 
        user.ManagementCycleId))
       .ThenInclude(x => x.Area)

Only the first line is checked as covered by sonarqube, all .Include() lines in the project are uncovered, what am I missing here?

0

There are 0 best solutions below