[pre-commit.ci] pre-commit autoupdate #138
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: Test | |
on: | |
pull_request: | |
push: | |
branches: | |
- main | |
jobs: | |
test: | |
runs-on: ${{ matrix.os }} | |
strategy: | |
# Keep running even if one variation of the job fail | |
fail-fast: false | |
matrix: | |
os: | |
- ubuntu-20.04 | |
python: | |
- "3.5" | |
- "3.6" | |
- "3.7" | |
- "3.8" | |
- "3.9" | |
- "3.10" | |
include: | |
- os: macos-latest | |
python: 3.8 | |
steps: | |
- uses: actions/checkout@v2 | |
- name: Install Python ${{ matrix.python }} | |
uses: actions/setup-python@v2 | |
with: | |
python-version: ${{ matrix.python }} | |
# preserve pip cache to speed up installation | |
- name: Cache pip | |
uses: actions/cache@v2 | |
with: | |
path: ~/.cache/pip | |
# Look to see if there is a cache hit for the corresponding requirements file | |
key: ${{ runner.os }}-pip-${{ hashFiles('*requirements.txt') }} | |
restore-keys: | | |
${{ runner.os }}-pip- | |
- name: Install Python dependencies | |
run: | | |
pip install --upgrade pip | |
pip install --upgrade --pre -r dev-requirements.txt . | |
pip freeze | |
- name: Run tests | |
run: | | |
pytest -v --color=yes --cov=wurlitzer test.py | |
- name: Submit codecov report | |
run: | | |
codecov |