anuraag016 / Jest-Coverage-Diff

Jest Coverage report diff as a comment for Pull requests
MIT License
59 stars 46 forks source link

"No changes to code coverage between base and head branch" when fullCoverageDiff: false #33

Open alexciesielski opened 3 years ago

alexciesielski commented 3 years ago

image

As a test I have written some additional unit tests in the PR implementing this coverage diff tool but however many unit tests I add I still get the same message.

I run this on an Angular application which I have jest configured for with jest-preset-angular. The coverage is definitely being generated, because when I set fullCoverageDiff to true I get a wall of text with the whole coverage (which unfortunately is just unreadable given the length).

      - name: Run unit tests and check coverage
        uses: anuraag016/Jest-Coverage-Diff@master
        with:
          fullCoverageDiff: false
          runCommand: npm run test:ci
          delta: 0.5
"test:ci": "ng test --ci --silent --bail --coverage --collect-coverage --coverage-directory='./' --coverage-reporters=json-summary",