Skip to content

Commit 8d5c174

Browse files
Merge pull request #518 from ChrisRackauckas-Claude/fix-ci-isolate-jet-qa
Fix CI: isolate JET/QA tests and fix Runic formatting
2 parents 3bdb6ed + 0c87e5d commit 8d5c174

6 files changed

Lines changed: 108 additions & 15 deletions

File tree

.github/workflows/QA.yml

Lines changed: 42 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,42 @@
1+
name: "QA"
2+
3+
on:
4+
pull_request:
5+
branches:
6+
- master
7+
paths-ignore:
8+
- 'docs/**'
9+
push:
10+
branches:
11+
- master
12+
paths-ignore:
13+
- 'docs/**'
14+
15+
concurrency:
16+
group: ${{ github.workflow }}-${{ github.ref }}
17+
cancel-in-progress: ${{ github.ref_name != github.event.repository.default_branch || github.ref != 'refs/tags/v*' }}
18+
19+
jobs:
20+
qa:
21+
name: "QA"
22+
runs-on: ubuntu-latest
23+
strategy:
24+
fail-fast: false
25+
matrix:
26+
version:
27+
- "1"
28+
- "lts"
29+
steps:
30+
- uses: actions/checkout@v6
31+
- uses: julia-actions/setup-julia@v2
32+
with:
33+
version: ${{ matrix.version }}
34+
- uses: julia-actions/cache@v2
35+
- name: "Instantiate test/jet"
36+
run: |
37+
julia --project=test/jet -e '
38+
using Pkg
39+
Pkg.develop(path=".")
40+
Pkg.instantiate()'
41+
- name: "Run QA tests"
42+
run: julia --project=test/jet test/jet/runtests.jl

Project.toml

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -25,18 +25,15 @@ SymbolicIndexingInterface = "2efcf032-c050-4f8e-a9bb-153293bab1f5"
2525
ADTypes = "1"
2626
Accessors = "0.1.38"
2727
AlgebraicMultigrid = "1"
28-
Aqua = "0.8"
2928
ArrayInterface = "7.17.1"
3029
CEnum = "0.5"
3130
DAEProblemLibrary = "0.1"
3231
DataStructures = "0.18, 0.19"
3332
DiffEqBase = "6.190.2"
3433
DiffEqCallbacks = "4"
3534
DifferentiationInterface = "0.6, 0.7"
36-
ExplicitImports = "1"
3735
ForwardDiff = "0.10"
3836
IncompleteLU = "0.2"
39-
JET = "0.11.2"
4037
Libdl = "1"
4138
LinearAlgebra = "1"
4239
LinearSolve = "3.40.0"
@@ -58,12 +55,9 @@ julia = "1.10"
5855
[extras]
5956
ADTypes = "47edcb42-4c32-4615-8424-f2b9edc5f35b"
6057
AlgebraicMultigrid = "2169fc97-5a83-5252-b627-83903c6c433c"
61-
Aqua = "4c88cf16-eb10-579e-8560-4a9242c79595"
62-
JET = "c3a54625-cd67-489e-a8e7-0a5a0ff4e31b"
6358
DAEProblemLibrary = "dfb8ca35-80a1-48ba-a605-84916a45b4f8"
6459
DiffEqCallbacks = "459566f4-90b8-5000-8ac3-15dfb0a30def"
6560
DifferentiationInterface = "a0c0ee7d-e4b9-4e03-894e-1c5f64a51d63"
66-
ExplicitImports = "7d51a73a-1435-4ff3-83d9-f097790105c7"
6761
ForwardDiff = "f6369f11-7733-5829-9624-2563aa707210"
6862
IncompleteLU = "40713840-3770-5561-ab4c-a76e7d0d7895"
6963
ModelingToolkit = "961ee093-0014-501f-94e3-6117800e7a78"
@@ -73,4 +67,4 @@ SparseConnectivityTracer = "9f842d2f-2579-4b1d-911e-f412cf18a3f5"
7367
Test = "8dfed614-e22c-5e08-85e1-65c5234f0b40"
7468

7569
[targets]
76-
test = ["Test", "ADTypes", "AlgebraicMultigrid", "Aqua", "DiffEqCallbacks", "ExplicitImports", "JET", "ODEProblemLibrary", "DAEProblemLibrary", "ForwardDiff", "DifferentiationInterface", "SparseConnectivityTracer", "IncompleteLU", "ModelingToolkit", "SafeTestsets"]
70+
test = ["Test", "ADTypes", "AlgebraicMultigrid", "DiffEqCallbacks", "ODEProblemLibrary", "DAEProblemLibrary", "ForwardDiff", "DifferentiationInterface", "SparseConnectivityTracer", "IncompleteLU", "ModelingToolkit", "SafeTestsets"]

src/common_interface/integrator_types.jl

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -149,6 +149,8 @@ mutable struct ARKODEIntegrator{
149149
ctx_handle::ContextHandle
150150
end
151151

152+
# runic: off
153+
# Runic reformats callable struct syntax in a way that is incompatible with Julia < 1.13
152154
function (integrator::ARKODEIntegrator{
153155
N, pType, solType, algType, fType, UFType, JType, oType,
154156
LStype, Atype, MLStype, Mtype, CallbackCacheType, ARKStepMem, IA,
@@ -220,6 +222,7 @@ function (integrator::ARKODEIntegrator{
220222
copyto!(out, out_nvec.v)
221223
return idxs === nothing ? out : @view out[idxs]
222224
end
225+
# runic: on
223226

224227
mutable struct IDAIntegrator{
225228
N,

test/jet/Project.toml

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
[deps]
2+
Aqua = "4c88cf16-eb10-579e-8560-4a9242c79595"
3+
ExplicitImports = "7d51a73a-1435-4ff3-83d9-f097790105c7"
4+
JET = "c3a54625-cd67-489e-a8e7-0a5a0ff4e31b"
5+
Sundials = "c3572dad-4567-51f8-b174-8c6c989267f4"
6+
Test = "8dfed614-e22c-5e08-85e1-65c5234f0b40"
7+
8+
[compat]
9+
Aqua = "0.8"
10+
ExplicitImports = "1"
11+
JET = "0.9, 0.10, 0.11"
12+
Sundials = "5"

test/jet/runtests.jl

Lines changed: 50 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,50 @@
1+
using Sundials
2+
using Test
3+
4+
@testset "Quality Assurance" begin
5+
using Aqua
6+
@testset "Aqua tests" begin
7+
Aqua.test_ambiguities(Sundials; recursive = false)
8+
Aqua.test_deps_compat(Sundials)
9+
Aqua.test_piracies(
10+
Sundials;
11+
treat_as_own = [Sundials.NVector],
12+
)
13+
Aqua.test_project_extras(Sundials)
14+
Aqua.test_stale_deps(Sundials)
15+
Aqua.test_unbound_args(Sundials)
16+
Aqua.test_undefined_exports(Sundials)
17+
end
18+
19+
using ExplicitImports
20+
@testset "ExplicitImports tests" begin
21+
@test check_no_implicit_imports(Sundials) === nothing
22+
@test check_no_stale_explicit_imports(Sundials) === nothing
23+
# AbstractSciMLOperator is re-exported from SciMLBase, so allow it
24+
@test check_all_explicit_imports_via_owners(
25+
Sundials;
26+
ignore = (:AbstractSciMLOperator,),
27+
) === nothing
28+
end
29+
end
30+
31+
@testset "JET Static Analysis" begin
32+
using JET
33+
# Test algorithm constructors for type stability
34+
@testset "Algorithm constructors" begin
35+
rep = JET.report_call(Sundials.CVODE_BDF, ())
36+
@test length(JET.get_reports(rep)) == 0
37+
38+
rep = JET.report_call(Sundials.CVODE_Adams, ())
39+
@test length(JET.get_reports(rep)) == 0
40+
41+
rep = JET.report_call(Sundials.IDA, ())
42+
@test length(JET.get_reports(rep)) == 0
43+
44+
rep = JET.report_call(Sundials.ARKODE, ())
45+
@test length(JET.get_reports(rep)) == 0
46+
47+
rep = JET.report_call(Sundials.KINSOL, ())
48+
@test length(JET.get_reports(rep)) == 0
49+
end
50+
end

test/runtests.jl

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -2,14 +2,6 @@ using Sundials
22
using SafeTestsets
33
using Test
44

5-
@testset "Quality Assurance" begin
6-
include("qa_test.jl")
7-
end
8-
9-
@testset "JET Static Analysis" begin
10-
include("jet_test.jl")
11-
end
12-
135
@testset "Generator" begin
146
include("generator.jl")
157
end

0 commit comments

Comments
 (0)