chore: update dependabot configuration #79
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
name: Run tests | |
on: [push] | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
strategy: | |
fail-fast: false | |
matrix: | |
python-version: ["3.8.18", "3.11.3"] | |
poetry-version: ["1.5.1"] | |
steps: | |
- uses: actions/checkout@v3 | |
# Poetry cache depends on OS, Python version and Poetry version. | |
- name: Cache Poetry cache | |
uses: actions/cache@v2 | |
with: | |
path: ~/.cache/pypoetry | |
key: poetry-cache-${{ runner.os }}-${{ matrix.python-version }}-${{ matrix.poetry-version }} | |
- name: Set up Python ${{ matrix.python-version }} | |
uses: actions/setup-python@v3 | |
with: | |
python-version: ${{ matrix.python-version }} | |
- name: Install poetry | |
uses: abatilo/actions-poetry@v2.0.0 | |
with: | |
poetry-version: ${{ matrix.poetry-version }} | |
- name: View poetry version | |
run: poetry --version | |
- name: Install dependencies | |
shell: bash | |
run: | | |
poetry install --with dev | |
# All python related commands should be executed by poetry run. | |
# Checkout the following examples. | |
- name: Lint with Ruff | |
shell: bash | |
run: | | |
poetry run ruff check . | |
- name: Test with pytest | |
shell: bash | |
run: | | |
touch ~/.bash_history | |
poetry run pytest -c pytest.ini -s |