CI: do not depend on make #164
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: tox | |
on: [push, pull_request] | |
permissions: | |
contents: read # to fetch code (actions/checkout) | |
env: | |
# note that some tools care only for the name, not the value | |
FORCE_COLOR: 1 | |
jobs: | |
tox: | |
name: ${{ matrix.os }} / ${{ matrix.python-version }} | |
# https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#jobsjob_idtimeout-minutes | |
timeout-minutes: 20 | |
runs-on: ${{ matrix.os }} | |
strategy: | |
fail-fast: false | |
matrix: | |
os: | |
- ubuntu-latest | |
# not defaulting to macos-latest: Python <= 3.9 was missing from macos-14 @ arm64 | |
- macos-13 | |
# Not testing Windows, because tests need Unix-only fcntl, grp, pwd, etc. | |
python-version: | |
# CPython <= 3.7 is EoL since 2023-06-27 | |
- "3.7" | |
- "3.8" | |
- "3.9" | |
- "3.10" | |
- "3.11" | |
- "3.12" | |
# PyPy <= 3.8 is EoL since 2023-06-16 | |
- "pypy-3.9" | |
- "pypy-3.10" | |
include: | |
# Note: potentially "universal2" release | |
# https://github.com/actions/runner-images/issues/9741 | |
- os: macos-latest | |
python-version: "3.12" | |
# will run these without showing red CI results should they fail | |
- os: macos-latest | |
python-version: "3.13" | |
unsupported: true | |
- os: ubuntu-latest | |
python-version: "3.13" | |
unsupported: true | |
# pin OS lower than usual tests, even if that is slow / soon removed | |
# point is to prove we got our minimum deps documented | |
- os: ubuntu-20.04 | |
python-version: "3.7" | |
mindep: true | |
steps: | |
- uses: actions/checkout@0ad4b8fadaa221de15dcec353f45205ec38ea70b # v4.1.4 | |
- name: Using Python ${{ matrix.python-version }} | |
uses: actions/setup-python@v5 | |
with: | |
python-version: ${{ matrix.python-version }} | |
cache: pip | |
cache-dependency-path: pyproject.toml | |
check-latest: true | |
allow-prereleases: ${{ matrix.unsupported || false }} | |
- name: "Install test Dependencies (cache hit: ${{ steps.setup-python.outputs.cache-hit }})" | |
run: | | |
python -m pip install --upgrade pip | |
python -m pip install tox | |
- run: tox -e run-module | |
timeout-minutes: 6 | |
continue-on-error: ${{ matrix.unsupported || false }} | |
- run: tox -e run-entrypoint | |
timeout-minutes: 6 | |
continue-on-error: ${{ matrix.unsupported || false }} | |
- run: tox -e py | |
continue-on-error: ${{ matrix.unsupported || false }} | |
- if: ${{ matrix.mindep || false }} | |
run: tox -e mindep | |
continue-on-error: ${{ matrix.unsupported || false }} | |
- name: Install dist dependencies | |
run: python -m pip install build | |
continue-on-error: ${{ matrix.unsupported || false }} | |
- name: build dist | |
run: python -m build | |
continue-on-error: ${{ matrix.unsupported || false }} |