diff --git a/test/qa/Project.toml b/test/qa/Project.toml index 03e281b..0a6b61b 100644 --- a/test/qa/Project.toml +++ b/test/qa/Project.toml @@ -11,5 +11,5 @@ EasyModelAnalysis = {path = "../.."} [compat] Aqua = "0.8" SafeTestsets = "1, 0.1" -SciMLTesting = "1" +SciMLTesting = "1.6" julia = "1.10" diff --git a/test/qa/qa.jl b/test/qa/qa.jl index 3b25a94..c0fc243 100644 --- a/test/qa/qa.jl +++ b/test/qa/qa.jl @@ -1,24 +1,33 @@ -using EasyModelAnalysis, Aqua -@testset "Aqua" begin - # find_persistent_tasks_deps Pkg.develop's each dependency. On Julia 1.12 a Pkg - # regression (JuliaLang/Pkg.jl#4587) makes Pkg.develop honor a developed - # dependency's relative [sources] and resolve it against the depot, so - # OptimizationBBO (which pins its in-repo OptimizationBase via [sources], as - # every Optimization.jl sublibrary does) errors with "expected package - # OptimizationBase to exist at path .../OptimizationBBO/OptimizationBase". The - # [sources] is correct and load-bearing for the monorepo; the bug is upstream. - # Remove this version gate once Pkg.jl#4587 is fixed (see EasyModelAnalysis#303). - if VERSION < v"1.12" - Aqua.find_persistent_tasks_deps(EasyModelAnalysis) - end - Aqua.test_ambiguities(EasyModelAnalysis, recursive = false) - Aqua.test_deps_compat(EasyModelAnalysis) - Aqua.test_piracies( - EasyModelAnalysis, - treat_as_own = [] - ) - Aqua.test_project_extras(EasyModelAnalysis) - Aqua.test_stale_deps(EasyModelAnalysis) - Aqua.test_unbound_args(EasyModelAnalysis) - Aqua.test_undefined_exports(EasyModelAnalysis, broken = true) -end +using SciMLTesting, EasyModelAnalysis, Test + +run_qa( + EasyModelAnalysis; + explicit_imports = true, + aqua_kwargs = (; ambiguities = (; recursive = false)), + # undefined_exports: `Variable` and `rotate!` leak in (dead) via `@reexport` + # (SciML/EasyModelAnalysis.jl#300) + aqua_broken = (:undefined_exports,), + ei_kwargs = (; + all_qualified_accesses_via_owners = (; + ignore = ( + # DynamicPPL.acclogp!! is reached through Turing's re-export; DynamicPPL + # is not a direct dependency, so accessing it via Turing is intentional. + :DynamicPPL, + # `value` is the Symbolics unwrap API, re-exported through ModelingToolkit + # (the direct dependency); accessing it as `ModelingToolkit.value` is intended. + :value, + ), + ), + all_qualified_accesses_are_public = (; + ignore = ( + :AbstractMCMCEnsemble, # AbstractMCMC: no public alias for the ensemble type + :DynamicPPL, # Turing: submodule re-export, no public alias + :LN_SBPLX, # NLopt: algorithm constant, not marked public + :value, # ModelingToolkit: Symbolics unwrap re-export, not marked public + ), + ), + ), + # no_implicit_imports: heavy reexport / bulk-using of the SciML stack + # (SciML/EasyModelAnalysis.jl#301) + ei_broken = (:no_implicit_imports,), +)