Skip to content

Commit

Permalink
Update model.jl
Browse files Browse the repository at this point in the history
  • Loading branch information
odow authored Feb 20, 2025
1 parent 15f4a6f commit 792cd12
Showing 1 changed file with 9 additions and 8 deletions.
17 changes: 9 additions & 8 deletions test/Utilities/model.jl
Original file line number Diff line number Diff line change
Expand Up @@ -595,15 +595,16 @@ function test_constraints_invalid_index()
return
end

MOI.Utilities.@struct_of_constraints_by_set_types(
Set4802,
Union{MOI.LessThan{T},MOI.GreaterThan{T}},
MOI.EqualTo{T},
MOI.ZeroOne,
Int,
)

function test_struct_of_constraints_by_set_types()
MOI.Utilities.@struct_of_constraints_by_set_types(
MySet1,
Union{MOI.LessThan{T},MOI.GreaterThan{T}},
MOI.EqualTo{T},
MOI.ZeroOne,
Int,
)
set = MySet1{Float64,Vector{Float64},Vector{Float64},Vector{Bool},Int}()
set = Set4802{Float64,Vector{Float64},Vector{Float64},Vector{Bool},Int}()
@test set.num_variables == 0
@test set.int === nothing
set.int = 1
Expand Down

0 comments on commit 792cd12

Please sign in to comment.