From d6bd929dd77217873684e8ac916ef486d4c45092 Mon Sep 17 00:00:00 2001 From: ChrisRackauckas-Claude Date: Fri, 3 Jul 2026 14:04:26 -0400 Subject: [PATCH] Restore top-level GPU test lane; drop vestigial AlgConvergence_II group The root package's GPU test lane was dropped during the pre-centralization sublibrary split (2026-03-18) and never re-added to the grouped-tests matrix, so `test/gpu/` became orphaned dead code -- nothing includes it and `test/runtests.jl` has no GPU group. Root-level GPU tests are integration tests (the `test/gpu` environment pulls the full OrdinaryDiffEq stack + the BDF/NonlinearSolve/RKIP/ Rosenbrock sublibraries via [sources]), distinct from the per-sublibrary GPU tests, so restore a top-level lane: - test/test_groups.toml: add a `[GPU]` group (`versions = ["1"]`, `runner = ["self-hosted","Linux","X64","gpu"]`, `timeout = 60`), matching the sublibrary GPU groups. - test/runtests.jl: add `activate_gpu_env()` + `gpu_group()` (develop the root package, activate test/gpu, include every `test/gpu/*.jl` under an isolated `@safetestset`) and wire `"GPU" => gpu_group` into the run_tests groups. Files are globbed so the set stays in sync as GPU tests are added/removed there. Also drop `[AlgConvergence_II]` from test/test_groups.toml: it was introduced by the matrix migration (#3730) but never had a folder, a thunk, or any tests, so it only spawned no-op CI jobs. Note: GPU tests execute only on the self-hosted `gpu` runner; they cannot be run in a CPU CI/dev environment. Validated locally: runtests.jl parses, the matrix emits the GPU cell, and the group-include mechanism runs isolated @safetestsets. Co-Authored-By: Chris Rackauckas --- test/runtests.jl | 22 ++++++++++++++++++++++ test/test_groups.toml | 6 ++++-- 2 files changed, 26 insertions(+), 2 deletions(-) diff --git a/test/runtests.jl b/test/runtests.jl index cb99cf9166f..3890024fa2e 100644 --- a/test/runtests.jl +++ b/test/runtests.jl @@ -191,6 +191,27 @@ function qa_group() return @time @safetestset "Quality Assurance Tests" include("qa/qa_tests.jl") end +function activate_gpu_env() + Pkg.activate(joinpath(@__DIR__, "gpu")) + Pkg.develop(PackageSpec(path = dirname(@__DIR__))) + return Pkg.instantiate() +end + +# Root (integration) GPU tests. The test/gpu environment pulls the full +# OrdinaryDiffEq stack plus the relevant sublibraries and runs on the self-hosted +# `gpu` runner (Julia 1, where [sources] is honored natively). Every file in +# test/gpu is included, so the set stays in sync as GPU tests are added or +# removed there without touching this dispatch. +function gpu_group() + is_APPVEYOR && return + activate_gpu_env() + gpudir = joinpath(@__DIR__, "gpu") + for f in sort(filter(f -> endswith(f, ".jl"), readdir(gpudir))) + @time @eval @safetestset $("GPU: " * f) include($(joinpath(gpudir, f))) + end + return nothing +end + @time begin # Monorepo sublibrary routing. The root reads GROUP to pick a `lib/` # sublibrary, transitively develops its `[sources]` on Julia < 1.11, then @@ -278,6 +299,7 @@ end "Downstream" => downstream_group, "AD" => ad_group, "ODEInterfaceRegression" => odeinterface_group, + "GPU" => gpu_group, ), # QA runs in the root test environment (no per-group Project.toml); # its body is the ExplicitImports testset, not the standard diff --git a/test/test_groups.toml b/test/test_groups.toml index b00bfe2f4eb..ce407bf197b 100644 --- a/test/test_groups.toml +++ b/test/test_groups.toml @@ -14,8 +14,6 @@ versions = ["lts", "1", "pre"] versions = ["lts", "1", "pre"] [AlgConvergence_I] versions = ["lts", "1", "pre"] -[AlgConvergence_II] -versions = ["lts", "1", "pre"] [AlgConvergence_III] versions = ["lts", "1", "pre"] [ModelingToolkit] @@ -33,3 +31,7 @@ versions = ["lts"] versions = ["lts", "1"] [ODEInterfaceRegression] versions = ["lts"] +[GPU] +versions = ["1"] +runner = ["self-hosted", "Linux", "X64", "gpu"] +timeout = 60