Skip to content

[pre-commit.ci] pre-commit autoupdate #1268

[pre-commit.ci] pre-commit autoupdate

[pre-commit.ci] pre-commit autoupdate #1268

Workflow file for this run

name: Test
on:
push:
branches:
- main
pull_request:
workflow_dispatch:
# allow manual runs on branches without a PR
concurrency:
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.sha }}
cancel-in-progress: true
permissions: {}
jobs:
pre-commit:
name: Pre-commit checks (Black, Flake8, MyPy, ...)
runs-on: ubuntu-latest
permissions:
contents: read
steps:
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
with:
persist-credentials: false
- uses: actions/setup-python@a309ff8b426b58ec0e2a45f0f869d46889d02405 # v6.2.0
with:
python-version: "3.10"
- uses: pre-commit/action@2c7b3805fd2a0fd8c1884dcaebf91fc102a13ecd # v3.0.1
test-dist:
name: Test SDist & wheel
needs: pre-commit
runs-on: ubuntu-latest
permissions:
contents: read
steps:
- name: Checkout
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
with:
persist-credentials: false
- name: Install CPython 3.10
uses: actions/setup-python@a309ff8b426b58ec0e2a45f0f869d46889d02405 # v6.2.0
with:
python-version: "3.10"
architecture: x64
- name: Run tests
run: pipx run nox -s test-sdist-3.10 test-wheel-3.10
test:
name: CPython ${{ matrix.python }} ${{ matrix.platform[0] }} on ${{ matrix.platform[1] }}
needs: test-dist
runs-on: ${{ matrix.platform[1] }}
environment: ${{ (github.repository == 'pypa/auditwheel' && ((github.event_name != 'pull_request') || (github.event.pull_request.head.repo.full_name == github.repository))) && 'codecov' || '' }}
permissions:
contents: read
strategy:
fail-fast: false
matrix:
platform:
- [ 'x86_64', 'ubuntu-24.04' ]
python: [ '3.10', '3.11', '3.12', '3.13', '3.14' ]
include:
- platform: [ 'aarch64', 'ubuntu-24.04-arm' ]
python: '3.12'
- platform: [ 'i686', 'ubuntu-24.04' ]
python: '3.12'
- platform: [ 'armv7l', 'ubuntu-24.04-arm' ]
python: '3.12'
- platform: [ 'ppc64le', 'ubuntu-24.04' ]
python: '3.12'
qemu: true
- platform: [ 's390x', 'ubuntu-24.04' ]
python: '3.12'
qemu: true
- platform: [ 'riscv64', 'ubuntu-24.04' ]
python: '3.12'
qemu: true
steps:
- name: Checkout
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
with:
persist-credentials: false
- name: Setup cache
uses: actions/cache@668228422ae6a00e4ad889ee87cd7109ec5666a7 # v5.0.4
with:
path: ~/.cache/auditwheel_tests
key: python${{ matrix.python }}-${{ matrix.platform[0] }}-${{ hashFiles('**/test_manylinux.py') }}
restore-keys: python${{ matrix.python }}-${{ matrix.platform[0] }}-
- name: Install CPython ${{ matrix.python }}
uses: actions/setup-python@a309ff8b426b58ec0e2a45f0f869d46889d02405 # v6.2.0
with:
python-version: "${{ matrix.python }}"
allow-prereleases: true
- name: Set up QEMU
if: matrix.qemu
uses: docker/setup-qemu-action@ce360397dd3f832beb865e1373c09c0e9f86d70a # v4.0.0
- name: Run tests
run: pipx run nox -s tests-${{ matrix.python }}
env:
AUDITWHEEL_ARCH: ${{ matrix.platform[0] }}
AUDITWHEEL_QEMU: ${{ matrix.qemu }}
- name: Upload coverage to codecov
if: github.repository == 'pypa/auditwheel'
uses: codecov/codecov-action@671740ac38dd9b0130fbe1cec585b89eea48d3de # v5.5.2
with:
token: ${{ secrets.CODECOV_TOKEN }}