1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153
|
name: Tests
on:
workflow_dispatch:
pull_request:
push:
branches:
- master
- develop
env:
FORCE_COLOR: 3
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
jobs:
clang-tidy:
name: Clang-Tidy
runs-on: ubuntu-latest
container: silkeh/clang:20
steps:
- name: Install requirements
run: apt-get update && apt-get install -y python3-dev python3-pip git ninja-build
- uses: actions/checkout@v6
with:
fetch-depth: 0
submodules: true
- name: Install extra requirements
run: python3 -m pip install setuptools_scm --break-system-packages
- name: Configure
run: cmake --preset tidy
- name: Build
run: cmake --build --preset tidy
pylint:
runs-on: ubuntu-latest
name: PyLint
steps:
- uses: actions/checkout@v6
with:
fetch-depth: 0
submodules: true
- name: Run PyLint
run: pipx run nox[uv] -s pylint -- --output-format=github
cmake:
name: CMake 🐍 ${{ matrix.python-version }}
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
include:
- python-version: "3.10"
cmake-extras: "-DCMAKE_CXX_STANDARD=17"
- python-version: "3.11"
- python-version: "3.14"
- python-version: "3.14t"
- python-version: "pypy3.11"
steps:
- uses: actions/checkout@v6
with:
fetch-depth: 0
submodules: true
- uses: actions/setup-python@v6
with:
python-version: ${{ matrix.python-version }}
allow-prereleases: true
- uses: rui314/setup-mold@v1
- uses: astral-sh/setup-uv@v7
- uses: hendrikmuhs/ccache-action@v1.2
with:
key: ${{ matrix.python-version }}
create-symlink: true
- name: Install python tools
run: uv pip install --system --python=python --group github
- name: Configure
run: cmake --preset default ${{ matrix.cmake-extras }}
- name: Build
run: cmake --build --preset default
- name: Test
run: ctest --preset default -j 4
build_wheels:
name: ${{ matrix.only }}
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
include:
- os: ubuntu-latest
only: cp314t-manylinux_x86_64
- os: ubuntu-24.04-arm
only: cp313-manylinux_aarch64
- os: windows-latest
only: cp310-win32
- os: windows-latest
only: cp313-win_amd64
- os: macos-15-intel
only: cp314t-macosx_x86_64
- os: macos-latest
only: cp312-macosx_arm64
- os: windows-11-arm
only: cp311-win_arm64
- os: ubuntu-latest
only: gp311_242-manylinux_x86_64
steps:
- uses: actions/checkout@v6
with:
submodules: true
fetch-depth: 0
- uses: astral-sh/setup-uv@v7
- uses: pypa/cibuildwheel@v3.3
with:
only: "${{ matrix.only }}"
- uses: actions/upload-artifact@v6
with:
path: wheelhouse/*
name: test-wheels-${{ strategy.job-index }}
- name: Check wheels
run: pipx run twine check wheelhouse/*
shell: bash
pass:
if: always()
needs: [clang-tidy, pylint, cmake, build_wheels]
runs-on: ubuntu-slim
steps:
- uses: re-actors/alls-green@release/v1
with:
jobs: ${{ toJSON(needs) }}
|