Skip to content

Commit 344d45c

Browse files
committed
Test suite: Add more test coverage for warn_if_unexpected_params() (only on Julia versions prior to 1.6)
1 parent 74bf0e8 commit 344d45c

File tree

1 file changed

+13
-0
lines changed

1 file changed

+13
-0
lines changed

Diff for: test/unit.jl

+13
Original file line numberDiff line numberDiff line change
@@ -24,3 +24,16 @@ end
2424
@test_throws ErrorException SlurmClusterManager.get_slurm_jobid_int()
2525
end
2626
end
27+
28+
@testset "warn_if_unexpected_params()" begin
29+
if Base.VERSION >= v"1.6"
30+
# This test is not relevant for Julia 1.6+
31+
else
32+
params = Dict(:env => ["foo" => "bar"])
33+
SlurmClusterManager.warn_if_unexpected_params(params)
34+
@test_logs(
35+
(:warn, "The user provided the `env` kwarg, but SlurmClusterManager.jl's support for the `env` kwarg requires Julia 1.6 or later"),
36+
SlurmClusterManager.warn_if_unexpected_params(params),
37+
)
38+
end
39+
end

0 commit comments

Comments
 (0)