Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions Project.toml
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
name = "BARON"
uuid = "2e2ca445-9e14-5b13-8677-4410f177f82b"
repo = "https://github.com/jump-dev/BARON.jl.git"
version = "0.7.0"
version = "0.8.0"

[deps]
MathOptInterface = "b8f27783-ece8-5eb3-8dc8-9495eed66fee"

[compat]
MathOptInterface = "0.10.9"
MathOptInterface = "1"
julia = "1.6"
2 changes: 1 addition & 1 deletion test/Project.toml
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,4 @@ MathOptInterface = "b8f27783-ece8-5eb3-8dc8-9495eed66fee"
Test = "8dfed614-e22c-5e08-85e1-65c5234f0b40"

[compat]
JuMP = "0.22"
JuMP = "0.23"
102 changes: 2 additions & 100 deletions test/moi_test.jl
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@ using Test

using MathOptInterface
const MOI = MathOptInterface
const MOIT = MOI.DeprecatedTest
const MOIU = MOI.Utilities
const MOIB = MOI.Bridges

Expand Down Expand Up @@ -52,106 +51,9 @@ function test_runtests()
)
return
end
@testset "New" begin
test_runtests()
end
@testset "Old" begin
@testset "Unit" begin
config = MOIT.Config(atol=1e-5, rtol=1e-4, infeas_certificates=true, duals=false)
# A number of test cases are excluded because loadfromstring! works only
# if the solver supports variable and constraint names.
exclude = ["delete_variable", # Deleting not supported.
"delete_variables", # Deleting not supported.
"solve_zero_one_with_bounds_1", # loadfromstring!
"solve_zero_one_with_bounds_2", # loadfromstring!
"solve_zero_one_with_bounds_3", # loadfromstring!
"getconstraint", # Constraint names not suported.
"solve_with_upperbound", # loadfromstring!
"solve_with_lowerbound", # loadfromstring!
"solve_integer_edge_cases", # loadfromstring!
"solve_affine_lessthan", # loadfromstring!
"solve_affine_greaterthan", # loadfromstring!
"solve_affine_equalto", # loadfromstring!
"solve_affine_interval", # loadfromstring!
"solve_duplicate_terms_vector_affine", # Vector variables
"solve_blank_obj", # loadfromstring!
"solve_affine_deletion_edge_cases", # Deleting not supported.
"number_threads", # NumberOfThreads not supported
"delete_nonnegative_variables", # get ConstraintFunction n/a.
"update_dimension_nonnegative_variables", # get ConstraintFunction n/a.
"delete_soc_variables", # VectorOfVar. in SOC not supported
"solve_result_index", # DualObjectiveValue not supported
"time_limit_sec", # Supported by Optimizer, but not by MOIU.Model
"silent",
"raw_status_string",
"solve_qp_edge_cases",
"solve_objbound_edge_cases",
#
"solve_farkas_interval_lower",
"solve_farkas_lessthan",
"solve_farkas_greaterthan",
"solve_farkas_variable_lessthan_max",
"solve_farkas_variable_lessthan",
"solve_farkas_equalto_upper",
"solve_farkas_interval_upper",
"solve_farkas_equalto_lower",
]
MOIT.unittest(caching_optimizer, config, exclude)
end

MOI.empty!(optimizer)

@testset "MOI Continuous Linear" begin
config = MOIT.Config(atol=1e-5, rtol=1e-4, infeas_certificates=false, duals=false)
excluded = String[
"linear7", # vector constraints
"linear8b", # certificate provided in this case (result count is 1)
"linear8c", # should be unbounded below, returns "Preprocessing found feasible solution with value -.200000000000E+052"
"linear15", # vector constraints
"partial_start" # TODO
]
# MOIT.partial_start_test(optimizer, config)
MOIT.contlineartest(caching_optimizer, config, excluded)
MOIT.linear8btest(caching_optimizer, MOIT.Config(atol=1e-5, rtol=1e-4, infeas_certificates=true, duals=false))
end

MOI.empty!(optimizer)

@testset "MOI Integer Linear" begin
config = MOIT.Config(atol=1e-5, rtol=1e-4, infeas_certificates=false, duals=false)
excluded = String[
"int2", # SOS1
"int3", # SOS1
"indicator1", # ACTIVATE_ON_ONE
"indicator2", # ACTIVATE_ON_ONE
"indicator3", # ACTIVATE_ON_ONE
"indicator4", # ACTIVATE_ON_ONE
"semiconttest",
"semiinttest",
]
MOIT.intlineartest(caching_optimizer, config, excluded)
end

MOI.empty!(optimizer)

@testset "MOI Continuous Quadratic" begin
# TODO: rather high tolerances
config = MOIT.Config(atol=1e-3, rtol=1e-3, infeas_certificates=false, duals=false)
excluded = String[
"qcp1", # vector constraints
]
MOIT.contquadratictest(caching_optimizer, config, excluded)
@testset "MOI Unit" begin
test_runtests()
end

MOI.empty!(optimizer)
bridged = MOIB.full_bridge_optimizer(optimizer, Float64)

@testset "MOI Nonlinear" begin
config = MOIT.Config(atol=1e-3, rtol=1e-3, infeas_certificates=false, duals=false)
excluded = String[
"nlp_objective_and_moi_objective",
]
MOIT.nlptest(bridged, config, excluded)
end
end#rm
end # module