Skip to content

Commit

Permalink
Fix SonarCloud Coverage
Browse files Browse the repository at this point in the history
  • Loading branch information
JackPlowman committed Sep 29, 2024
1 parent 20586b8 commit 79e4d02
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 2 deletions.
6 changes: 6 additions & 0 deletions .github/workflows/code-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,12 @@ jobs:
- name: Run Unit Tests
run: just unit-test

- name: test
run: cat coverage.xml

- name: Override Coverage Source Path for Sonar
run: sed -i "s/<source>\/home\/runner\/work\/github-stats-analyser\/github-stats-analyser\/source>/<source>\/github\/workspace<\/source>/g" /home/runner/work/github-stats-analyser/github-stats-analyser/coverage.xml

- name: SonarCloud Scan
uses: SonarSource/[email protected]
env:
Expand Down
4 changes: 2 additions & 2 deletions Justfile
Original file line number Diff line number Diff line change
Expand Up @@ -34,10 +34,10 @@ run-with-defaults:
DEBUG=true REPOSITORY_OWNER=JackPlowman poetry run python -m analyser

unit-test:
poetry run pytest analyser --cov=analyser --cov-report=xml
poetry run pytest analyser --cov=. --cov-report=xml

unit-test-debug:
poetry run pytest analyser --cov=analyser --cov-report=xml -vvvv
poetry run pytest analyser --cov=. --cov-report=xml -vvvv

validate-schema:
poetry run check-jsonschema --schemafile test/schema_validation/repository_statistics_schema.json test/schema_validation/repository_statistics.json
Expand Down

0 comments on commit 79e4d02

Please sign in to comment.