meson: add disabledTests support (#552282)

This commit is contained in:
Jan Tojnar
2026-09-27 19:10:48 +00:00
committed by GitHub
3 changed files with 16 additions and 0 deletions

View File

@@ -92,3 +92,10 @@ Meson setup hook.
- `prefixKey`
- `enableParallelBuilding`
- `enableParallelChecking`
- `disabledTests`
#### `disabledTests` {#meson-disabled-tests}
Specifies a list of tests to skip in `mesonCheckPhase`.
You can optionally specify a subproject using a colon prefix, e.g. `subproject:test_name`.
Meson will pick up the main project name as a default if no subproject is specified.

View File

@@ -2984,6 +2984,9 @@
"meson-honored-variables": [
"index.html#meson-honored-variables"
],
"meson-disabled-tests": [
"index.html#meson-disabled-tests"
],
"setup-hook-mpi-check": [
"index.html#setup-hook-mpi-check"
],

View File

@@ -63,6 +63,12 @@ mesonCheckPhase() {
flagsArray+=("--timeout-multiplier=0")
fi
local _disabledTestsArray=()
concatTo _disabledTestsArray disabledTests
for disabledTest in "${_disabledTestsArray[@]}"; do
flagsArray+=("--exclude" "$disabledTest")
done
# Parallel building is enabled by default.
local buildCores=1
if [ "${enableParallelBuilding-1}" ]; then