Restructure Core/QA test harness to SciMLTesting v1.2 folder-discovery#385
Merged
ChrisRackauckas merged 2 commits intoJun 16, 2026
Merged
Conversation
The v1.2 conversion (SciML#384) placed the QA group inside the `groups` Dict passed to `run_tests`. SciMLTesting treats "QA" as a reserved group that must be supplied via the dedicated `qa` keyword argument; with `qa` unset, requesting `GROUP=QA` threw ArgumentError: run_tests: GROUP="QA" was requested but no `qa` body was provided Move the QA spec out of `groups` and into the `qa` keyword. Also add SafeTestsets and SciMLTesting (with compat) to test/qa/Project.toml. The QA body runs in the activated qa env and is wrapped in @safetestset, so that env must provide both packages, matching every other group env (test/Project.toml, test/Autodiff, test/Downstream all declare them). Verified locally on Julia 1.10 via the faithful CI path (GROUP=QA Pkg.test("ComponentArrays")): QA group 22/22 passed. Co-Authored-By: Chris Rackauckas <accounts@chrisrackauckas.com> Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Replace the explicit-args run_tests(core=..., groups=..., qa=..., all=["Core"])
with pure folder-discovery: test/runtests.jl is now just
using SciMLTesting
run_tests()
Behavior is preserved exactly:
- Core: delete test/core_tests.jl. The 19 self-contained top-level test/*.jl
files (each begins with include("shared/test_setup.jl")) are discovered as
Core, each run in its own isolated @safetestset (Core/<basename>) — identical
isolation to what core_tests.jl did manually. Local Core run matches the
pre-change aggregate exactly: 459 Pass, 9 Broken, 468 Total, each file once
(no double-run).
- QA: delete test/qa/qa.jl so test/qa/{aqua_tests,jet_tests}.jl are discovered
directly (qa.jl was a bare include-aggregator; both files are already
self-contained with their own using Aqua/JET/ComponentArrays/Test, so no
shared usings needed migrating). Each runs once: QA/aqua_tests.jl,
QA/jet_tests.jl.
- All = Core only: the old all=["Core"] excluded Autodiff/GPU/Downstream/
Reactant from the All lane. In discovery mode this is in_all = false on each
of those four groups (QA is auto-excluded from All). Verified GROUP=All runs
the 19 Core testsets only — no Autodiff/GPU/Downstream/Reactant/QA.
test/shared/ is a helper folder (not in test_groups.toml, a subdir not a
top-level *.jl) so discovery auto-excludes it. Existing per-group versions are
unchanged. GROUP=Autodiff still dispatches its sub-env (sanity-checked).
Co-Authored-By: Chris Rackauckas <accounts@chrisrackauckas.com>
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Restructure Core/QA to SciMLTesting v1.2 folder-discovery
This PR converts ComponentArrays' test harness from the explicit-args
run_tests(core=..., groups=..., qa=..., all=["Core"])form to SciMLTestingv1.2 folder-discovery mode.
test/runtests.jlis now simply:This is a pure restructure — behavior is preserved exactly (verified locally
on Julia 1.10, the
[compat]floor).What changed
test/core_tests.jl. That file was a hand-writtenaggregator that
@safetestset-included the 19 flat top-leveltest/*.jlfiles. Each of those files is self-contained (every one begins with
include("shared/test_setup.jl")), so folder-discovery now picks them up asCore and runs each in its own isolated
@safetestset(Core/<basename>) —identical isolation to what
core_tests.jldid manually.test/qa/qa.jl(a bareinclude("aqua_tests.jl"); include("jet_tests.jl")aggregator). Discovery now runstest/qa/aqua_tests.jland
test/qa/jet_tests.jldirectly. Both files are already self-contained(each has its own
using Aqua/using JET/using ComponentArrays/using Test), so no sharedusings needed migrating.all = ["Core"]excluded Autodiff/GPU/Downstream/Reactant from the "All" lane. In discovery mode this is expressed by setting
in_all = falseon each of those four groups intest/test_groups.toml(QA is auto-excluded from "All" by SciMLTesting). Each group's existing
versionsis unchanged.test/shared/is a helper folder (not declared intest_groups.toml, and asubdir rather than a top-level
*.jl), so discovery auto-excludes it.Local verification (Julia 1.10, SciMLTesting v1.2.0)
GROUP=Core: 19 discoveredCore/*testsets, each run exactly once(no double-run), aggregate 459 Pass, 9 Broken, 468 Total — identical to the
pre-change
core_tests.jlrun (459/9/468). The 9 Broken are pre-existing@test_brokens inbroadcasting_tests.jl, untouched by this PR.GROUP=QA: exactly 2 testsets —QA/aqua_tests.jl(9 Pass) andQA/jet_tests.jl(13 Pass), each once, all green.GROUP=All: runs the 19 Core testsets only — zeroAutodiff/GPU/Downstream/Reactant/QA testsets — confirming
in_all = falseworks. Aggregate 459/9/468, matching Core.
GROUP=Autodiff(sanity): still dispatches its sub-env and runsAutodiff/autodiff_tests.jl(64 Pass), Core not run.No tests were skipped,
@test_broken/@test_skip-ed, loosened, orwarnonly-ed.Please ignore until reviewed by @ChrisRackauckas.
🤖 Generated with Claude Code