Skip to content

Commit

Permalink
Incorporate yml updates from examples
Browse files Browse the repository at this point in the history
  • Loading branch information
endolith committed Jun 28, 2024
1 parent 7f17c9e commit 14e1ca3
Showing 1 changed file with 12 additions and 7 deletions.
19 changes: 12 additions & 7 deletions .github/workflows/python-package.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,12 @@ name: Run linter, tests, and upload coverage report

on:
push:
branches: [ '*' ]
branches: [ "*" ]
pull_request:
branches: [ '*' ]
branches: [ "*" ]

permissions:
contents: read

jobs:
build:
Expand All @@ -16,18 +19,21 @@ jobs:
strategy:
fail-fast: false
matrix:
python-version: ["3.7", "3.8", "3.9", "3.10"]
python-version: ["3.7", "3.8", "3.9", "3.10", "3.11", "3.12"]

steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v4
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python-version }}
# You can test your matrix by printing the current Python version
- name: Display Python version
run: python -c "import sys; print(sys.version)"
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install flake8
pip install flake8 pytest pytest-cov
if [ -f requirements.txt ]; then pip install -r requirements.txt; fi
- name: Install package
run: |
Expand All @@ -40,7 +46,6 @@ jobs:
flake8 . --count --exit-zero --max-complexity=10 --max-line-length=127 --statistics
- name: Test with pytest, generate coverage report
run: |
pip install pytest pytest-cov
pytest --cov=./ --cov-report=xml
- name: Upload coverage to Codecov
uses: codecov/codecov-action@v3.1.1

0 comments on commit 14e1ca3

Please sign in to comment.