Skip to content

Commit

Permalink
Adjust pipeline to grab coverage data
Browse files Browse the repository at this point in the history
  • Loading branch information
VemundFredriksen committed Oct 15, 2023
1 parent 0b08f21 commit a6b391c
Show file tree
Hide file tree
Showing 3 changed files with 16 additions and 2 deletions.
6 changes: 4 additions & 2 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,8 +25,10 @@ jobs:
- name: Install dependencies
run: pip install -r requirements.txt

- name: Run pytest with coverage
run: pytest --cov=synthlung
- name: Install tox
run: pip install tox
- name: Run tox
run: tox -e py

- name: SonarCloud Scan
uses: SonarSource/sonarcloud-github-action@master
Expand Down
1 change: 1 addition & 0 deletions sonar-project.properties
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
sonar.projectKey=VemundFredriksen_SynthLung
sonar.organization=vemundfredriksen

sonar.python.coverage.reportPaths=coverage.xml
# This is the name and version displayed in the SonarCloud UI.
#sonar.projectName=SynthLung
#sonar.projectVersion=1.0
Expand Down
11 changes: 11 additions & 0 deletions tox.ini
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
[tox]
envlist = py39
skipsdist = True

[testenv]
deps =
pytest
pytest-cov
commands = pytest --cov=my_project --cov-report=xml --cov-config=tox.ini --cov-branch

[coverage:run]

0 comments on commit a6b391c

Please sign in to comment.