Skip to content

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

[pre-commit.ci] pre-commit autoupdate

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

Workflow file for this run

name: Test
on:
workflow_dispatch:
pull_request:
types:
- opened
- synchronize
branches:
- main
paths:
- 'src/**'
- 'tests/**'
- '!**.pyi'
- 'tox.ini'
- 'pyproject.toml'
- 'requirements/*.in'
- '.github/actions/setup-tox/**'
- '.github/workflows/test.yml'
push:
branches:
- main
- release/**
tags-ignore:
- '*'
paths:
- 'src/**'
- 'tests/**'
- '!**.pyi'
- 'tox.ini'
- 'pyproject.toml'
- 'requirements/*.in'
- '.github/actions/setup-tox/**'
- '.github/workflows/test.yml'
concurrency:
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.sha }}
cancel-in-progress: true
jobs:
test:
if: |
(github.event_name != 'push' || !startsWith(github.event.head_commit.message, 'Bump version:'))
&& (github.event_name != 'pull_request' || github.event.pull_request.draft != true)
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
os: [ubuntu-20.04, windows-2022, macos-12]
python_version: ['3.10']
steps:
- uses: actions/checkout@v4
with:
submodules: true
- name: Setup Python ${{ matrix.python_version }}
id: setup-python
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python_version }}
- name: Setup tox
uses: ./.github/actions/setup-tox
- name: Launch tests
run: tox run -f py$(echo ${{ matrix.python_version }} | tr -d .)