Skip to content

[pre-commit.ci] pre-commit autoupdate #52

[pre-commit.ci] pre-commit autoupdate

[pre-commit.ci] pre-commit autoupdate #52

Workflow file for this run

name: 'Run tests'
on:
push:
branches: [main]
pull_request:
jobs:
test:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
# If you wanted to use multiple Python versions, you'd have specify a matrix in the job and
# reference the matrixe python version here.
- uses: actions/setup-python@v2
with:
python-version: 3.11
# Cache the installation of Poetry
- name: cache poetry install
uses: actions/cache@v2
with:
path: ~/.local
key: poetry-1.1.12-0
# Install Poetry
- uses: snok/install-poetry@v1
with:
virtualenvs-create: true
virtualenvs-in-project: true
# Cache dependencies
- name: cache deps
id: cache-deps
uses: actions/cache@v2
with:
path: .venv
key: pydeps-${{ hashFiles('**/poetry.lock') }}
# Install dependencies
- run: poetry install --no-interaction --no-root
if: steps.cache-deps.outputs.cache-hit != 'true'
- run: poetry install --no-interaction
- run: poetry run pytest