Skip to content

Commit

Permalink
add MWE from issue #67 as test case
Browse files Browse the repository at this point in the history
  • Loading branch information
rschwarz committed May 17, 2018
1 parent 302eabb commit 9be9088
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions test/more_tests.jl
Original file line number Diff line number Diff line change
Expand Up @@ -94,3 +94,15 @@ end
@test getvalue(x) 1.0
@test getvalue(y) 1.0
end

@testset "test_#67_nlp_without_obj" begin
m = Model(solver=SCIPSolver("display/verblevel", 0))
@variable(m, -5 <= x <= 5)
@NLconstraint(m, x <= 2)

solve(m)
xval = getvalue(x)

@test xval <= 2 + 1e-4
@test xval >= -5 - 1e-4
end

0 comments on commit 9be9088

Please sign in to comment.