Skip to content
This repository has been archived by the owner on Apr 19, 2024. It is now read-only.

feat: switch to poethepoet for tasks #83

feat: switch to poethepoet for tasks

feat: switch to poethepoet for tasks #83

Workflow file for this run

name: Run tests
on:
workflow_call:
pull_request:
push:
jobs:
test:
strategy:
matrix:
os: [ubuntu-latest, macos-latest, windows-latest]
python-version: ['3.12', '3.11', '3.10', '3.9', '3.8', '3.7']
runs-on: ${{ matrix.os }}
name: Tox on ${{ matrix.os }} - v${{ matrix.python-version }}
steps:
- uses: actions/checkout@v2
# Load the cached installation of Poetry
- name: Load cached Poetry installation
id: cached-poetry
uses: actions/cache@v2
with:
path: ~/.local
key: poetry-${{ runner.os }}-${{ hashFiles('poetry.lock') }}
# Install & configure Poetry
- name: Install Poetry
run: pipx install poetry==1.7.1
# Install Python
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}
cache: 'poetry'
- name: Setup poetry
run: |
poetry config virtualenvs.create true --local
poetry config virtualenvs.in-project true --local
- name: Install dependencies and DisCapTy
run: poetry install
# Run DisCapTy's tests
- name: Run tests
run: poetry run poe test
- name: Export Coverage
run: poetry run coverage json
- name: Upload coverage reports to Codecov
uses: codecov/codecov-action@v3