48 lines
1.0 KiB
YAML
Raw Normal View History

2021-09-22 19:28:17 +00:00
name: Tests
on:
push: ~
pull_request: ~
jobs:
build:
runs-on: ubuntu-latest
timeout-minutes: 10 # Don't run forever when stale
strategy:
matrix:
python-version:
2022-04-20 19:28:31 +00:00
- '3.7'
- '3.8'
- '3.9'
- '3.10'
2022-12-07 19:30:58 +00:00
- '3.11'
- '3.12'
2021-09-22 19:28:17 +00:00
name: Python ${{ matrix.python-version }}
steps:
- uses: actions/checkout@v4
2021-09-22 19:28:17 +00:00
- name: Setup Python ${{ matrix.python-version }}
uses: actions/setup-python@v5
2021-09-22 19:28:17 +00:00
with:
python-version: ${{ matrix.python-version }}
- name: Cached PIP dependencies
uses: actions/cache@v4
2021-09-22 19:28:17 +00:00
with:
path: |
~/.cache/pip
~/.tox/python/.pytest_cache
key: pip-${{ matrix.python-version }}-${{ hashFiles('setup.py', 'tox.ini') }}
restore-keys: pip-${{ matrix.python-version }}-
- name: Install dependencies
run: pip install tox
2021-09-22 19:28:17 +00:00
- name: Run tests
run: tox
2021-09-22 19:28:17 +00:00
- name: Code coverage upload
uses: codecov/codecov-action@v4