Fix CI issues with Python version #81
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
on: | |
pull_request: | |
branches: [main, master] | |
push: | |
branches: [main, master] | |
name: test-coverage | |
jobs: | |
test-coverage: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v3 | |
- name: Setup python | |
uses: actions/setup-python@v4 | |
with: | |
python-version: 3.x | |
- name: Run pytest | |
run: | | |
pip install pytest pytest-cov | |
pip install -r requirements.txt | |
pytest --cov=./ --cov-report=xml | |
- name: Upload to codecov | |
uses: codecov/codecov-action@v3 | |
with: | |
token: ${{ secrets.CODECOV_TOKEN }} | |
files: ./coverage.xml | |
- name: Upload artifact | |
if: failure() | |
uses: actions/upload-artifact@v3 | |
with: | |
name: coverage-results | |
path: ./coverage.xml |