Skip to content

Commit

Permalink
changed github worflow in this branch
Browse files Browse the repository at this point in the history
  • Loading branch information
nucccc committed Dec 3, 2023
1 parent f632501 commit da87eeb
Showing 1 changed file with 25 additions and 5 deletions.
30 changes: 25 additions & 5 deletions .github/workflows/cov.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ on:

jobs:
cov_job:
runs-on: ubuntu latest
runs-on: ubuntu-latest
name: checking coverage
permissions:
pull-requests: write
Expand All @@ -22,11 +22,31 @@ jobs:
- name: install whatever
run: pip install .

- name: install pytest
run: pip install pytest

- name: launch test
run: pytest
run: python3 -m pytest

- name: launch coverage
run:
coverage run -m pytest

- name: force htmlcov
run:
git add -f htmlcov/*

- name: cov comment
id: coverage-comment
- name: cov_comment
id: coverage_comment
uses: py-cov-action/python-coverage-comment-action@v3
with:
GITHUB_TOKEN: ${{ github.token }}
GITHUB_TOKEN: ${{ github.token }}

- name: Store Pull Request comment to be posted
uses: actions/upload-artifact@v3
if: steps.coverage_comment.outputs.COMMENT_FILE_WRITTEN == 'true'
with:
# If you use a different name, update COMMENT_ARTIFACT_NAME accordingly
name: python-coverage-comment-action
# If you use a different name, update COMMENT_FILENAME accordingly
path: python-coverage-comment-action.txt

0 comments on commit da87eeb

Please sign in to comment.