Change error handling method & Change setuptools to hatchling #9
Workflow file for this run
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: Tests | |
on: | |
push: | |
branches: [ main ] | |
pull_request: | |
branches: [ main ] | |
workflow_call: | |
workflow_dispatch: | |
jobs: | |
pre_commit: | |
name: π§Ή Linting | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
name: ποΈ Checkout | |
- name: π Cache pre-commit paths | |
uses: actions/cache@v3 | |
with: | |
path: | | |
~/.cache/pip | |
$RUNNER_TOOL_CACHE/Python/* | |
~/.cache/pre-commit | |
key: ${{ runner.os }}-build-${{ matrix.python-version }}-${{ | |
hashFiles('.pre-commit-config.yaml') }} | |
- uses: actions/setup-python@v4 | |
name: π Set Python Version | |
with: | |
python-version: 3.8 | |
- name: βοΈ Install-pre-commit | |
run: python -m pip install --upgrade pre-commit | |
- name: π Run Pre-commit | |
run: pre-commit run --all-files | |
test: | |
name: π§ͺ Tests | |
needs: [ pre_commit ] | |
runs-on: ${{ matrix.os }} | |
strategy: | |
matrix: | |
os: [ubuntu-latest] | |
python-version: ['3.10', '3.11', '3.12'] | |
steps: | |
- uses: actions/checkout@v2 | |
name: ποΈ Checkout | |
with: | |
ref: ${{github.event.pull_request.head.ref}} | |
- name: π Set up Python ${{ matrix.python-version }} | |
uses: actions/setup-python@v4 | |
with: | |
python-version: ${{ matrix.python-version }} | |
- name: βοΈ Install dependencies | |
run: python -m pip install --upgrade pip tox tox-gh-actions | |
- name: π§ͺ Run tests with tox | |
run: tox |