File tree Expand file tree Collapse file tree 1 file changed +36
-0
lines changed
Expand file tree Collapse file tree 1 file changed +36
-0
lines changed Original file line number Diff line number Diff line change @@ -946,6 +946,42 @@ function test_dual_vector()
946946 return
947947end
948948
949+ function test_nl_con ()
950+ model = Model ()
951+ set_silent (model)
952+ @variable (model, x)
953+ @constraint (model, c1, x^ 3 == 0 )
954+ @objective (model, Min, x)
955+
956+ data = ModelAnalyzer. analyze (
957+ ModelAnalyzer. Feasibility. Analyzer (),
958+ model,
959+ primal_point = Dict (JuMP. index (x) => 0.0 ),
960+ dual_point = Dict (JuMP. index (c1) => 0.0 ),
961+ )
962+ @show list = ModelAnalyzer. list_of_issue_types (data)
963+ @test length (list) == 0
964+ return
965+ end
966+
967+ function test_nl_obj ()
968+ model = Model ()
969+ set_silent (model)
970+ @variable (model, x)
971+ @constraint (model, c1, x == 0 )
972+ @objective (model, Min, x^ 3 )
973+
974+ data = ModelAnalyzer. analyze (
975+ ModelAnalyzer. Feasibility. Analyzer (),
976+ model,
977+ primal_point = Dict (JuMP. index (x) => 0.0 ),
978+ dual_point = Dict (JuMP. index (c1) => 0.0 ),
979+ )
980+ @show list = ModelAnalyzer. list_of_issue_types (data)
981+ @test length (list) == 0
982+ return
983+ end
984+
949985end # module
950986
951987TestDualFeasibilityChecker. runtests ()
You can’t perform that action at this time.
0 commit comments