diff --git a/Project.toml b/Project.toml index 5743db0..15bb3f8 100644 --- a/Project.toml +++ b/Project.toml @@ -20,6 +20,7 @@ HiGHS = "1" Ipopt = "1" JSON = "1" MathOptInterface = "1.19" +ParallelTestRunner = "2.1.0" Polyhedra = "0.8" Printf = "1.10.0" Test = "1" @@ -29,8 +30,9 @@ julia = "1.10" HiGHS = "87dc4568-4c63-4d18-b0c0-bb2238e4078b" Ipopt = "b6b21f68-93f8-5de0-b562-5493be1d77c9" JSON = "682c06a0-de6a-54ab-a142-c8b1cf79cde6" +ParallelTestRunner = "d3525ed8-44d0-4b2c-a655-542cee43accc" Polyhedra = "67491407-f73d-577b-9b50-8179a7c68029" Test = "8dfed614-e22c-5e08-85e1-65c5234f0b40" [targets] -test = ["HiGHS", "Ipopt", "JSON", "Test", "Polyhedra"] +test = ["HiGHS", "Ipopt", "JSON", "ParallelTestRunner", "Polyhedra", "Test"] diff --git a/test/algorithms/Chalmet.jl b/test/algorithms/test_Chalmet.jl similarity index 100% rename from test/algorithms/Chalmet.jl rename to test/algorithms/test_Chalmet.jl diff --git a/test/algorithms/Dichotomy.jl b/test/algorithms/test_Dichotomy.jl similarity index 100% rename from test/algorithms/Dichotomy.jl rename to test/algorithms/test_Dichotomy.jl diff --git a/test/algorithms/DominguezRios.jl b/test/algorithms/test_DominguezRios.jl similarity index 100% rename from test/algorithms/DominguezRios.jl rename to test/algorithms/test_DominguezRios.jl diff --git a/test/algorithms/EpsilonConstraint.jl b/test/algorithms/test_EpsilonConstraint.jl similarity index 100% rename from test/algorithms/EpsilonConstraint.jl rename to test/algorithms/test_EpsilonConstraint.jl diff --git a/test/algorithms/Hierarchical.jl b/test/algorithms/test_Hierarchical.jl similarity index 100% rename from test/algorithms/Hierarchical.jl rename to test/algorithms/test_Hierarchical.jl diff --git a/test/algorithms/KirlikSayin.jl b/test/algorithms/test_KirlikSayin.jl similarity index 100% rename from test/algorithms/KirlikSayin.jl rename to test/algorithms/test_KirlikSayin.jl diff --git a/test/algorithms/Lexicographic.jl b/test/algorithms/test_Lexicographic.jl similarity index 100% rename from test/algorithms/Lexicographic.jl rename to test/algorithms/test_Lexicographic.jl diff --git a/test/algorithms/RandomWeighting.jl b/test/algorithms/test_RandomWeighting.jl similarity index 100% rename from test/algorithms/RandomWeighting.jl rename to test/algorithms/test_RandomWeighting.jl diff --git a/test/algorithms/Sandwiching.jl b/test/algorithms/test_Sandwiching.jl similarity index 100% rename from test/algorithms/Sandwiching.jl rename to test/algorithms/test_Sandwiching.jl diff --git a/test/algorithms/TambyVanderpooten.jl b/test/algorithms/test_TambyVanderpooten.jl similarity index 100% rename from test/algorithms/TambyVanderpooten.jl rename to test/algorithms/test_TambyVanderpooten.jl diff --git a/test/runtests.jl b/test/runtests.jl index 73ca276..bdbdc66 100644 --- a/test/runtests.jl +++ b/test/runtests.jl @@ -3,14 +3,16 @@ # v.2.0. If a copy of the MPL was not distributed with this file, You can # obtain one at http://mozilla.org/MPL/2.0/. -using Test +is_test_file(f) = startswith(f, "test_") && endswith(f, ".jl") -@testset "$file" for file in readdir(joinpath(@__DIR__, "algorithms")) - include(joinpath(@__DIR__, "algorithms", file)) -end - -@testset "$file" for file in readdir(@__DIR__) - if startswith(file, "test_") && endswith(file, ".jl") - include(joinpath(@__DIR__, file)) +testsuite = Dict{String,Expr}() +for (root, dirs, files) in walkdir(@__DIR__) + for file in joinpath.(root, filter(is_test_file, files)) + testsuite[file] = :(include($file)) end end + +import MultiObjectiveAlgorithms +import ParallelTestRunner + +ParallelTestRunner.runtests(MultiObjectiveAlgorithms, ARGS; testsuite)