File tree Expand file tree Collapse file tree
src/submodules/FileFormats Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -7,4 +7,4 @@ MathOptInterface = "b8f27783-ece8-5eb3-8dc8-9495eed66fee"
77[compat ]
88Documenter = " 0.27.10"
99JSON = " 0.21"
10- JSONSchema = " 0.3 "
10+ JSONSchema = " 1 "
Original file line number Diff line number Diff line change @@ -228,7 +228,7 @@ julia> good_model = JSON.parse("""
228228 }
229229 """);
230230
231- julia> isvalid(good_model, schema )
231+ julia> isvalid(schema, good_model )
232232true
233233```
234234
@@ -247,13 +247,13 @@ julia> bad_model = JSON.parse("""
247247 }
248248 """);
249249
250- julia> isvalid(bad_model, schema )
250+ julia> isvalid(schema, bad_model )
251251false
252252```
253253
254254Use ` JSONSchema.validate ` to obtain more insight into why the validation failed:
255255``` jldoctest schema_mof
256- julia> JSONSchema.validate(bad_model, schema )
256+ julia> JSONSchema.validate(schema, bad_model )
257257Validation failed:
258258path: [variables][1]
259259instance: Dict{String, Any}("NaMe" => "x")
You can’t perform that action at this time.
0 commit comments