Skip to content

Run unit tests

Run unit tests #519

Workflow file for this run

name: Run unit tests
on:
pull_request:
push:
branches: [ main ]
tags:
- '*'
workflow_dispatch:
schedule:
# Run every Tuesday at 03:53 UTC
- cron: 53 3 * * 2
jobs:
tests:
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
# The aim with the matrix below is to walk through a representative but not full combination of OS, Python, and pytest versions.
matrix:
include:
- os: ubuntu-latest
python-version: '3.8'
toxenv: py38-test-pytestoldest
- os: windows-latest
python-version: '3.8'
toxenv: py38-test-pytest50
- os: macos-13
python-version: '3.8'
toxenv: py38-test-pytest51
- os: ubuntu-latest
python-version: '3.8'
toxenv: py38-test-pytest52
- os: windows-latest
python-version: '3.8'
toxenv: py38-test-pytest53
- os: ubuntu-latest
python-version: '3.8'
toxenv: py38-test-pytest60
- os: ubuntu-latest
python-version: '3.9'
toxenv: py39-test-pytest61
- os: ubuntu-latest
python-version: '3.9'
toxenv: py39-test-pytest62
- os: ubuntu-latest
python-version: '3.10'
toxenv: py310-test-pytest70
- os: ubuntu-latest
python-version: '3.10'
toxenv: py310-test-pytest71
- os: windows-latest
python-version: '3.11'
toxenv: py311-test-pytest72
- os: ubuntu-latest
python-version: '3.11'
toxenv: py311-test-pytest73
- os: ubuntu-latest
python-version: '3.11'
toxenv: py311-test-pytest74
- os: ubuntu-latest
python-version: '3.12'
toxenv: py312-test-pytest80
- os: windows-latest
python-version: '3.12'
toxenv: py312-test-pytest81
- os: ubuntu-latest
python-version: '3.12'
toxenv: py312-test-pytest82
- os: macos-latest
python-version: '3.13-dev'
toxenv: py312-test-pytest83
- os: windows-latest
python-version: '3.13-dev'
toxenv: py312-test-pytestdev
- os: macos-latest
python-version: '3.11'
toxenv: py311-test-pytestdev
- os: ubuntu-latest
python-version: '3.12'
toxenv: py312-test-pytestdev-numpydev
- os: ubuntu-latest
python-version: '3.13-dev'
toxenv: py313-test-pytestdev
steps:
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
with:
fetch-depth: 0
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@0b93645e9fea7318ecaed2b359559ac225c90a2b # v5.3.0
with:
python-version: ${{ matrix.python-version }}
- name: Install Tox
run: python -m pip install tox
- name: Run Tox
run: tox ${{ matrix.toxargs }} -v -e ${{ matrix.toxenv }}