Is there any way to analyze code coverage for a pull request?

Hi there I was wondering if I could get some help with PR analysis. It’s really important for us to be able to check code coverage for pull requests but this is unavailable with automatic scanning. I’d like to be able to manually scan the new code with the github action but it doesn’t seem to work during a pull request and gives me the error I’ve provided below. It there any sort of workaround for this so I can just manually run a scan during the workflow run? I’ve got a .net repo set up that works perfectly with this action here https://github.com/marketplace/actions/dotnet-sonarscanner that lets me provide a test command. It’d be nice if there was an option like this for other languages. Thanks.

  • ALM used: GitHub
  • CI system used: Github Actions
  • Scanner command used when applicable: sonarsource/sonarcloud-github-action@master
  • Languages of the repository: JS, JSX
  • Error observed:
No need to run analysis. It is already triggered by the push event.
  • Steps to reproduce: Use the sonarcloud github action in a PR workflow.

Incase anyone else has this same issue, I found this action here https://github.com/marketplace/actions/scan-with-sonar-scanner that works well for this. My workflow wound up looking like this.

jobs:
  sonar_scan:

    runs-on: ubuntu-latest

    steps:
    - uses: actions/checkout@v1
    - name: yarn test
      run: |
        yarn
        yarn --coverage
      env:
        CI: true
    - uses: mathrix-education/sonar-scanner@master
      with:
        version: 4.2.0.1873 # required
        scan: true
        args: -D:sonar.login=${{ secrets.SONAR_TOKEN }}