Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 3 additions & 9 deletions .github/workflows/CI.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,14 +12,8 @@ concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: ${{ startsWith(github.ref, 'refs/pull/') }}
jobs:
test:
name: "Tests"
strategy:
fail-fast: false
matrix:
version:
- "1"
uses: "SciML/.github/.github/workflows/tests.yml@v1"
tests:
uses: "SciML/.github/.github/workflows/grouped-tests.yml@v1"
with:
julia-version: "${{ matrix.version }}"
group-env-name: PPS_TEST_GROUP
secrets: "inherit"
2 changes: 2 additions & 0 deletions Project.toml
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@ ForwardDiff = "0.10, 1.3"
JET = "0.9, 0.10, 0.11"
KernelAbstractions = "0.9"
LineSearch = "0.1"
LinearAlgebra = "1"
NonlinearSolveBase = "2.24"
Optimization = "4.1, 5.2"
PrecompileTools = "1"
Expand All @@ -40,6 +41,7 @@ SciMLBase = "2.79, 3.0"
Setfield = "1.1"
SimpleNonlinearSolve = "2.12"
StaticArrays = "1.9"
Test = "1"
julia = "1.10"

[extras]
Expand Down
1 change: 1 addition & 0 deletions test/Project.toml
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ JET = "c3a54625-cd67-489e-a8e7-0a5a0ff4e31b"
KernelAbstractions = "63c18a36-062a-441e-b654-da1e3ab1ce7c"
LinearAlgebra = "37e2e46d-f89d-539d-b4ee-838fcccc9c8e"
Optimization = "7f7a1694-90dd-40f0-9382-eb1efda571ba"
Pkg = "44cfe95a-1eb2-52ea-b672-e2afdf69b78f"
QuasiMonteCarlo = "8a4e6c94-4038-4cdc-81c3-7e6ffdb2a71b"
Random = "9a3f8284-a2c9-5f02-9a11-845980a1fd5c"
SafeTestsets = "1bc83da4-3b8d-516f-aca4-4fe02f6d838f"
Expand Down
File renamed without changes.
13 changes: 13 additions & 0 deletions test/qa/Project.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
[deps]
JET = "c3a54625-cd67-489e-a8e7-0a5a0ff4e31b"
ParallelParticleSwarms = "ab63da0c-63b4-40fa-a3b7-d2cba5be6419"
StaticArrays = "90137ffa-7385-5640-81b9-e52037218182"
Test = "8dfed614-e22c-5e08-85e1-65c5234f0b40"

[sources]
ParallelParticleSwarms = {path = "../.."}

[compat]
JET = "0.9, 0.10, 0.11"
StaticArrays = "1.9"
julia = "1.10"
33 changes: 21 additions & 12 deletions test/runtests.jl
Original file line number Diff line number Diff line change
@@ -1,18 +1,27 @@
using Pkg
using SafeTestsets
using Test

global CI_GROUP = get(ENV, "GROUP", "CPU")
const TEST_GROUP = get(ENV, "PPS_TEST_GROUP", "Core")

@safetestset "Regression tests" include("./regression.jl")
@safetestset "Reinitialization tests" include("./reinit.jl")
@safetestset "JET static analysis" include("./jet.jl")
if TEST_GROUP == "QA"
Pkg.activate(joinpath(@__DIR__, "qa"))
Pkg.develop(PackageSpec(path = joinpath(@__DIR__, "..")))
Pkg.instantiate()
include("qa.jl")
else
global CI_GROUP = get(ENV, "GROUP", "CPU")

#TODO: Current throws warning for redefinition with the use of @testset multiple times. Migrate to TestItemRunners.jl
@testset for BACKEND in unique(("CPU", CI_GROUP))
global GROUP = BACKEND
@testset "$(BACKEND) optimizers tests" include("./gpu.jl")
GC.gc(true)
@testset "$(BACKEND) optimizers with constraints tests" include("./constraints.jl")
GC.gc(true)
@testset "$(BACKEND) hybrid optimizers" include("./lbfgs.jl")
@safetestset "Regression tests" include("./regression.jl")
@safetestset "Reinitialization tests" include("./reinit.jl")

#TODO: Current throws warning for redefinition with the use of @testset multiple times. Migrate to TestItemRunners.jl
@testset for BACKEND in unique(("CPU", CI_GROUP))
global GROUP = BACKEND
@testset "$(BACKEND) optimizers tests" include("./gpu.jl")
GC.gc(true)
@testset "$(BACKEND) optimizers with constraints tests" include("./constraints.jl")
GC.gc(true)
@testset "$(BACKEND) hybrid optimizers" include("./lbfgs.jl")
end
end
5 changes: 5 additions & 0 deletions test/test_groups.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
[Core]
versions = ["lts", "1", "pre"]

[QA]
versions = ["lts", "1"]
Loading