Skip to content

Update GH Actions (#96) #218

Update GH Actions (#96)

Update GH Actions (#96) #218

Workflow file for this run

name: Tests
on:
pull_request:
push:
branches:
- master
jobs:
build:
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
python: ["3.8", "3.9", "3.10", "3.11", "3.12", "3.13"]
os: [ubuntu-22.04, windows-2022]
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Set up Python ${{ matrix.python }}
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python }}
- name: Set up PDM
uses: pdm-project/setup-pdm@v4
with:
python-version: ${{ matrix.python }}
cache: true
- name: Setup VC
uses: ilammy/msvc-dev-cmd@v1
if: contains(matrix.os, 'windows')
- name: Install CMake
if: contains(matrix.os, 'ubuntu')
run: |
CMAKE_VERSION=3.25.1
curl -sSL https://github.com/Kitware/CMake/releases/download/v${CMAKE_VERSION}/cmake-${CMAKE_VERSION}-linux-x86_64.tar.gz | tar xz
sudo cp -rT cmake-${CMAKE_VERSION}-linux-x86_64 /usr/local
- name: Install dependencies
run: |
cmake --version
python -m pip install --upgrade setuptools pip wheel
python -m pip install tox tox-gh-actions
- name: Test with tox
run: |
tox
env:
os: ${{ matrix.os }}
- name: Upload coverage reports to Codecov
uses: codecov/codecov-action@v4
with:
token: ${{ secrets.CODECOV_TOKEN }}
flags: unittests
name: Python ${{ matrix.python }} on ${{ matrix.os }}
fail_ci_if_error: false