SonarQube Developer Pull request analysis code coverage for Android

Pproduct: SonarQube developer edition
Version: 7.7
Platform: Android
Language: Kotlin
VCS: GitHub Enterprise

What am I trying to achieve

Have SonarQube publish coverage information and duplication information for Pull Request Analysis for Android.

What have I done so far

The long lived branch is the master branch.

Regular and Branch analysis are successfully setup for Android projects where the code coverage information is visible in the SonarQube dashboard.

Android is set up to use the Gradle plugin. We use jacoco and we provided the reports by specifying sonar.coverage.jacoco.xmlReportPaths.

PR analysis is set up as per the docs and there is a GitHub Enterprise App that adds the checks on PRs.
Here is a screenshot to confirm.

However, as is visible from the bottom of the image - there is no coverage information collected by the scanner for the PR analysis.

and visiting the dashboard I see not coverage and duplication information in the Code tab.

Question

What is necessary to have the PR analysis collect coverage information? Is there a special key for PR analysis that needs to be set?

Pproduct: SonarQube developer edition
Version: 7.7
Platform: iOS
Language: Swift
VCS: GitHub Enterprise

What am I trying to achieve

Have SonarQube publish coverage information and duplication information for Pull Request Analysis for Android.

What have I done so far

The long lived branch is the master branch.

Regular and Branch analysis are successfully setup for iOS projects where the code coverage information is visible in the SonarQube dashboard.

iOS is configured via sonar-project.properties file. Here we use sonar.coverageReportPaths. The coverage file is compiles using the iOS script in the sample repository on GitHub.

PR analysis is set up as per the docs and there is a GitHub Enterprise App that adds the checks on PRs.
Here is a screenshot to confirm.

However, as is visible from the bottom of the image - there is no coverage information collected by the scanner for the PR analysis.

and visiting the dashboard I see not coverage and duplication information.

Question

What is necessary to have the PR analysis collect coverage information for iOS? Is there a special key for PR analysis that needs to be set?

Hi Aleksandar,

I see that you are using SonarQube 7.7. It is highly recommended that you upgrade to SonarQube 7.9.1 LTS to take advantage of improvements and fixes .

Can you verify that you are seeing Coverage information in SonarQube for these scans? Go to your project in SonarQube and use the branch dropdown to find the branch for your PR. If you are not seeing coverage in SonarQube, there is likely a configuration issue in your scan. See the Java and Swift entries (there is a separate process for Swift 9.3+) in the Test Coverage section of the Test Coverage and Execution documentation page.

Cheers.

Brian