chore: Fix unit tests #944
Workflow file for this run
This file contains hidden or 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: Python Unit CI | ||
on: | ||
push: | ||
branches: | ||
- main | ||
pull_request: | ||
permissions: | ||
contents: read | ||
jobs: | ||
test: | ||
strategy: | ||
matrix: | ||
python: ['3.7', '3.8', '3.9', '3.10', '3.11', '3.12'] | ||
platform: [ubuntu-latest, macos-latest, windows-latest] | ||
# Python <= 3.9 is not available on macos-14 | ||
# Workaround for https://github.com/actions/setup-python/issues/696 | ||
exclude: | ||
- os: macos-latest | ||
Check failure on line 19 in .github/workflows/unit.yml
|
||
python-version: '3.9' | ||
- os: macos-latest | ||
python-version: '3.8' | ||
- os: macos-latest | ||
python-version: '3.7' | ||
include: | ||
- os: macos-latest | ||
python-version: '3.9' | ||
- os: macos-13 | ||
python-version: '3.8' | ||
- os: macos-13 | ||
python-version: '3.7' | ||
runs-on: ${{ matrix.platform }} | ||
steps: | ||
- name: Harden Runner | ||
uses: step-security/harden-runner@63c24ba6bd7ba022e95695ff85de572c04a18142 # v2.7.0 | ||
with: | ||
disable-sudo: true | ||
egress-policy: block | ||
allowed-endpoints: > | ||
auth.docker.io:443 | ||
files.pythonhosted.org:443 | ||
github.com:443 | ||
production.cloudflare.docker.com:443 | ||
pypi.org:443 | ||
registry-1.docker.io:443 | ||
- name: Checkout | ||
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1 | ||
- name: Use Python ${{ matrix.python }} | ||
uses: actions/setup-python@0a5c61591373683505ea898e09a3ea4f39ef2b9c # v5.0.0 | ||
with: | ||
python-version: ${{ matrix.python }} | ||
- name: Install tox | ||
run: python -m pip install tox | ||
- name: Test | ||
run: python -m tox -e py-${{ matrix.platform }} |