Skip to content

Commit 554f789

Browse files
committed
add more tests
1 parent 79d3cb0 commit 554f789

File tree

1 file changed

+13
-0
lines changed

1 file changed

+13
-0
lines changed

test/params.jl

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,3 +6,16 @@
66
@test mipm.smplxparam.it_lim == 5910
77
@test mipm.param.tol_obj == 1.52e-3
88
end
9+
10+
@testset "Set MPB parameters" begin
11+
# setparameters! on model
12+
lpm = MathProgBase.LinearQuadraticModel(GLPKSolverLP())
13+
MathProgBase.setparameters!(lpm, TimeLimit=23.0)
14+
@test lpm.param.tm_lim == 23000.0
15+
16+
# setparameters! on solver
17+
lps = GLPKSolverLP()
18+
MathProgBase.setparameters!(lps, TimeLimit=23.0)
19+
lpm2 = MathProgBase.LinearQuadraticModel(lps)
20+
@test lpm2.param.tm_lim == 23000.0
21+
end

0 commit comments

Comments
 (0)