Skip to content

Commit

Permalink
Try a different workflow to run the unit tests
Browse files Browse the repository at this point in the history
  • Loading branch information
jaharkes committed Jul 25, 2024
1 parent 8f23afa commit e5a6cab
Showing 1 changed file with 17 additions and 10 deletions.
27 changes: 17 additions & 10 deletions .github/workflows/python.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,8 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Check out repository
uses: actions/checkout@v3
- name: Set up python
uses: actions/checkout@v4
- name: Install Python
uses: actions/setup-python@v4
with:
python-version: "3.8"
Expand All @@ -30,20 +30,27 @@ jobs:
needs: pre-commit
strategy:
matrix:
python-version: [3.7, "3.10"]
python-version: ["3.7", "3.10"]
runs-on: ubuntu-latest
steps:
- name: Check out repository
uses: actions/checkout@v3
- name: Install poetry
run: pipx install poetry
- name: Set up python
id: setup-python
uses: actions/checkout@v4
- name: Install Python
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}
cache: 'poetry'
- name: Install project
- name: Install poetry
uses: abatilo/actions-poetry@v2
- name: Setup local environment for caching
run: |
poetry config virtualenvs.create true --local
poetry config virtualenvs.in-project true --local
- name: Define cache for virtual environments
uses: actions/cache@v3
with:
path: ./.venv
key: venv-${{ hashFiles('poetry.lock') }}
- name: Install project dependencies
run: poetry install --no-interaction
- name: Run tests
run: poetry run pytest -v tests/

0 comments on commit e5a6cab

Please sign in to comment.