Skip to content

Commit bd63d55

Browse files
committed
switch to using ParallelTestRunner.jl
1 parent 750916e commit bd63d55

3 files changed

Lines changed: 28 additions & 26 deletions

File tree

test/Project.toml

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -4,13 +4,12 @@ name = "AlgorithmsInterfaceTests"
44
AlgorithmsInterface = "d1e3940c-cd12-4505-8585-b0a4b322527d"
55
Aqua = "4c88cf16-eb10-579e-8560-4a9242c79595"
66
Dates = "ade2ca70-3891-5945-98fb-dc099432e06a"
7-
SafeTestsets = "1bc83da4-3b8d-516f-aca4-4fe02f6d838f"
7+
ParallelTestRunner = "d3525ed8-44d0-4b2c-a655-542cee43accc"
88
Test = "8dfed614-e22c-5e08-85e1-65c5234f0b40"
99

10+
[sources]
11+
AlgorithmsInterface = {path = ".."}
12+
1013
[compat]
1114
Aqua = "0.8"
12-
SafeTestsets = "0.1"
1315
Test = "1.10"
14-
15-
[sources]
16-
AlgorithmsInterface = {path = ".."}

test/aqua.jl

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
using AlgorithmsInterface
2+
using Aqua
3+
4+
Aqua.test_all(AlgorithmsInterface)

test/runtests.jl

Lines changed: 20 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -1,24 +1,23 @@
1-
using SafeTestsets, Test
1+
# Test entry point — uses ParallelTestRunner.jl to run test files in parallel
2+
# worker processes (auto-discovered from `test/`).
3+
#
4+
# Run locally:
5+
# julia --project=test test/runtests.jl # run all tests
6+
# julia --project=test test/runtests.jl --list # list discovered test files
7+
# julia --project=test test/runtests.jl --help # show full usage
8+
# julia --project=test test/runtests.jl <name> [<name>…] # only files whose
9+
# # name starts with <name>
10+
#
11+
# Or from the Julia REPL:
12+
# using Pkg; Pkg.test("AlgorithmsInterface";
13+
# test_args=["--jobs=4", "--verbose"])
14+
#
15+
# Useful CLI options:
16+
# --jobs=N number of worker processes (default: chosen from CPU/memory)
17+
# --verbose print per-test timing, compile time, and memory stats
18+
# --quickfail abort the whole run on the first failure
219

3-
# these have to be included here to make show tests behave
20+
using ParallelTestRunner
421
using AlgorithmsInterface
5-
using Dates
622

7-
@testset "AlgorithmsInterface.jl" begin
8-
@safetestset "Newton" begin
9-
include("newton.jl")
10-
end
11-
12-
@safetestset "Stopping Criteria" begin
13-
include("stopping_criterion.jl")
14-
end
15-
16-
@safetestset "Logging Infrastructure" begin
17-
include("logging.jl")
18-
end
19-
20-
@safetestset "Aqua" begin
21-
using AlgorithmsInterface, Aqua
22-
Aqua.test_all(AlgorithmsInterface)
23-
end
24-
end
23+
runtests(AlgorithmsInterface, ARGS)

0 commit comments

Comments
 (0)