diff --git a/src/FileFormats/LP/LP.jl b/src/FileFormats/LP/LP.jl index 7c0bf663d4..a7e949736d 100644 --- a/src/FileFormats/LP/LP.jl +++ b/src/FileFormats/LP/LP.jl @@ -430,6 +430,8 @@ const _KEYWORDS = Dict( "gen" => _KW_INTEGER, "general" => _KW_INTEGER, "generals" => _KW_INTEGER, + "integer" => _KW_INTEGER, + "integers" => _KW_INTEGER, # _KW_BINARY "bin" => _KW_BINARY, "binary" => _KW_BINARY, diff --git a/test/FileFormats/LP/LP.jl b/test/FileFormats/LP/LP.jl index 3b2d928f5f..40988027a2 100644 --- a/test/FileFormats/LP/LP.jl +++ b/test/FileFormats/LP/LP.jl @@ -247,6 +247,22 @@ function test_free_variables_reading() return end +function test_integer_variables_reading() + for case in ["general", "GeneRalS", "Integer", "InTegeRs"] + io = IOBuffer() + write(io, "Minimize\nobj: x\nsubject to\n$case\nx\nEnd") + seekstart(io) + model = MOI.FileFormats.LP.Model() + read!(io, model) + out = IOBuffer() + write(out, model) + seekstart(out) + file = read(out, String) + @test occursin("General\nx\nEnd", file) + end + return +end + function test_quadratic_objective_diag() model = LP.Model() MOI.Utilities.loadfromstring!(