Skip to content
Merged
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
7 changes: 4 additions & 3 deletions src/Test/test_model.jl
Original file line number Diff line number Diff line change
Expand Up @@ -810,15 +810,16 @@ end
::Config{T},
) where {T}

Test that setting a lower-bound twice throws `UpperBoundAlreadySet`.
Test that setting an upper-bound twice throws `UpperBoundAlreadySet`.
"""
function test_model_UpperBoundAlreadySet(
model::MOI.ModelLike,
::Config{T},
config::Config{T},
) where {T}
@requires MOI.supports_constraint(model, MOI.VariableIndex, MOI.LessThan{T})
@requires _supports(config, MOI.delete)
x = MOI.add_variable(model)
ub = T(0)
@requires MOI.supports_constraint(model, MOI.VariableIndex, MOI.LessThan{T})
sets = [MOI.EqualTo(ub), MOI.Interval(ub, ub)]
set2 = MOI.LessThan(ub)
for set1 in sets
Expand Down