Scanning and code coverage from diffrent gitlab runner

Hi,

I’m currently facing an issue with my dotnet project. I’ve configured the build process and test execution to occur in separate steps. I initiate the dotnet scanner in one step and conclude it in a different step. However, this approach is encountering difficulties due to the presence of hardlinks in the generated files.

I’m wondering if it’s possible to generate relative paths instead. This might resolve the issue I’m facing.

Moreover, I’m hesitant to replace the old paths with new ones in all coverage files. Is there a way to manage this without manual replacement?

Here are the versions I’m using:

  • dotnet-sonarscanner: 5.15.0
  • SonarQube server: 9.9.3

The deployment is handled within GitLab CI/CD.

Any guidance or assistance on resolving this matter would be greatly appreciated. Thank you.

Hi,

The paths in your coverage report need to match the paths analysis is seeing.

Unfortunately, changing what your coverage engine generates is beyond our scope.

 
Ann

Hi,

Appreciate your prompt response.

Our coverage engine is dotnet-sonarscanner, and I believe this tool falls within the scope you mentioned.

Best regards,

Quentin

Hi Quentin,

dotnet-sonarscanner is the analyzer. It reads the coverage reports generated by some other process. Yes, dotnet-sonarscanner is in our scope, but it’s not what’s at issue here.

 
Ann

1 Like