mirror of https://github.com/jab/bidict.git
56 lines
2.1 KiB
YAML
56 lines
2.1 KiB
YAML
name: Test
|
|
"on": # quotes ensure this is never parsed as `true`
|
|
schedule:
|
|
- cron: "0 11 * * 5"
|
|
push:
|
|
branches:
|
|
- main
|
|
- dev
|
|
- deps
|
|
pull_request:
|
|
branches:
|
|
- main
|
|
jobs:
|
|
tests:
|
|
name: ${{ matrix.name }}
|
|
runs-on: ${{ matrix.os || 'ubuntu-latest' }}
|
|
strategy:
|
|
fail-fast: false
|
|
matrix:
|
|
include:
|
|
# See the following link for all available Python versions:
|
|
# https://raw.githubusercontent.com/actions/python-versions/main/versions-manifest.json
|
|
- {name: '3.10', python: '3.10', tox: py310}
|
|
- {name: '3.9', python: '3.9', tox: py39}
|
|
- {name: '3.8', python: '3.8', tox: py38}
|
|
- {name: '3.7', python: '3.7', tox: py37}
|
|
- {name: PyPy3.9, python: pypy-3.9, tox: pypy39}
|
|
- {name: PyPy3.8, python: pypy-3.8, tox: pypy38}
|
|
- {name: PyPy3.7, python: pypy-3.7, tox: pypy37}
|
|
# Skip Mac and Windows as nothing in bidict varies by OS.
|
|
# - {name: Mac, python: '3.10', tox: py310, os: macos-latest}
|
|
# - {name: Windows, python: '3.10', tox: py310, os: windows-latest}
|
|
steps:
|
|
- uses: actions/checkout@v2
|
|
- uses: actions/setup-python@v2
|
|
with:
|
|
python-version: ${{ matrix.python }}
|
|
cache: pip
|
|
cache-dependency-path: ${{ matrix.reqs || 'requirements/tests.txt' }}
|
|
- run: pip install -U pip && pip install -U setuptools wheel
|
|
- name: cache .hypothesis dir
|
|
uses: actions/cache@v2
|
|
with:
|
|
path: .hypothesis
|
|
key: hypothesis|${{ runner.os }}|${{ matrix.python }}
|
|
- run: pip install tox
|
|
- run: tox -e ${{ matrix.tox }}
|
|
# https://github.com/codecov/codecov-action
|
|
- name: Upload coverage to Codecov
|
|
uses: codecov/codecov-action@v2
|
|
# coverage only enabled for "py37" and "py310" envs in tox.ini
|
|
if: matrix.tox == 'py37' || matrix.tox == 'py310'
|
|
with:
|
|
verbose: true
|
|
fail_ci_if_error: false # https://github.com/codecov/codecov-action/issues/557
|