Triggering execution of Java tests #309
1076 tests run, 0 skipped, 31 failed.
Annotations
github-actions / Test Report
OpenApiToJsonSchemaTest.secondaryYamlWithOneOf
JSON schemas MUST match.
Expected: is <{"oneOf":[{"$ref":"#/definitions/typeA"},{"$ref":"#/definitions/typeB"}],"definitions":{"typeA":{"required":["typeAValueA"],"type":"object","properties":{"typeAValueA":{"type":"string"}}},"typeB":{"required":["typeBValueB"],"type":"object","properties":{"typeBValueB":{"type":"number"}}}},"$schema":"http://json-schema.org/draft-04/schema#"}>
but: was <{"oneOf":[{"$ref":"#/definitions/typeA"},{"$ref":"#/definitions/typeB"}],"definitions":{"typeA":{"required":["typeAValueA"],"type":"object","properties":{"typeAValueA":{"type":"string","types":["string"]}},"types":["object"]},"typeB":{"required":["typeBValueB"],"type":"object","properties":{"typeBValueB":{"type":"number","types":["number"]}},"types":["object"]}},"$schema":"http://json-schema.org/draft-04/schema#"}>
Raw output
java.lang.AssertionError: JSON schemas MUST match.
Expected: is <{"oneOf":[{"$ref":"#/definitions/typeA"},{"$ref":"#/definitions/typeB"}],"definitions":{"typeA":{"required":["typeAValueA"],"type":"object","properties":{"typeAValueA":{"type":"string"}}},"typeB":{"required":["typeBValueB"],"type":"object","properties":{"typeBValueB":{"type":"number"}}}},"$schema":"http://json-schema.org/draft-04/schema#"}>
but: was <{"oneOf":[{"$ref":"#/definitions/typeA"},{"$ref":"#/definitions/typeB"}],"definitions":{"typeA":{"required":["typeAValueA"],"type":"object","properties":{"typeAValueA":{"type":"string","types":["string"]}},"types":["object"]},"typeB":{"required":["typeBValueB"],"type":"object","properties":{"typeBValueB":{"type":"number","types":["number"]}},"types":["object"]}},"$schema":"http://json-schema.org/draft-04/schema#"}>
at org.hamcrest.MatcherAssert.assertThat(MatcherAssert.java:20)
at com.ebay.openapi.export.jsonschema.OpenApiToJsonSchemaTest.secondaryYamlWithOneOf(OpenApiToJsonSchemaTest.java:70)
github-actions / Test Report
OpenApiToJsonSchemaTest.testNullableAllOfReference
JSON schemas MUST match.
Expected: is <{"type":["object","null"],"properties":{"banana":{"type":"integer"},"apple":{"type":"string"}},"definitions":{"Response":{"type":["object","null"],"properties":{"banana":{"type":"integer"},"apple":{"type":"string"}},"additionalProperties":false},"ExtraType":{"type":"object","properties":{"apple":{"type":"string"},"banana":{"type":"integer"}},"additionalProperties":false}},"$schema":"http://json-schema.org/draft-04/schema#","additionalProperties":false}>
but: was <{"type":["object","null"],"properties":{"banana":{"type":"integer","types":["integer"]},"apple":{"type":"string","types":["string"]}},"types":["object"],"definitions":{"Response":{"type":["object","null"],"properties":{"banana":{"type":"integer","types":["integer"]},"apple":{"type":"string","types":["string"]}},"types":["object"],"additionalProperties":false},"ExtraType":{"type":"object","properties":{"apple":{"type":"string","types":["string"]},"banana":{"type":"integer","types":["integer"]}},"types":["object"],"additionalProperties":false}},"$schema":"http://json-schema.org/draft-04/schema#","additionalProperties":false}>
Raw output
java.lang.AssertionError: JSON schemas MUST match.
Expected: is <{"type":["object","null"],"properties":{"banana":{"type":"integer"},"apple":{"type":"string"}},"definitions":{"Response":{"type":["object","null"],"properties":{"banana":{"type":"integer"},"apple":{"type":"string"}},"additionalProperties":false},"ExtraType":{"type":"object","properties":{"apple":{"type":"string"},"banana":{"type":"integer"}},"additionalProperties":false}},"$schema":"http://json-schema.org/draft-04/schema#","additionalProperties":false}>
but: was <{"type":["object","null"],"properties":{"banana":{"type":"integer","types":["integer"]},"apple":{"type":"string","types":["string"]}},"types":["object"],"definitions":{"Response":{"type":["object","null"],"properties":{"banana":{"type":"integer","types":["integer"]},"apple":{"type":"string","types":["string"]}},"types":["object"],"additionalProperties":false},"ExtraType":{"type":"object","properties":{"apple":{"type":"string","types":["string"]},"banana":{"type":"integer","types":["integer"]}},"types":["object"],"additionalProperties":false}},"$schema":"http://json-schema.org/draft-04/schema#","additionalProperties":false}>
at org.hamcrest.MatcherAssert.assertThat(MatcherAssert.java:20)
at com.ebay.openapi.export.jsonschema.OpenApiToJsonSchemaTest.testNullableAllOfReference(OpenApiToJsonSchemaTest.java:282)
github-actions / Test Report
OpenApiToJsonSchemaTest.testRequestInlineSchema
JSON schemas MUST match.
Expected: is <{"type":"object","properties":{"name":{"type":"string"}},"definitions":{"Response":{"type":"object","properties":{"id":{"type":"string"}}}},"$schema":"http://json-schema.org/draft-04/schema#"}>
but: was <{"type":"object","properties":{"name":{"type":"string","types":["string"]}},"types":["object"],"definitions":{"Response":{"type":"object","properties":{"id":{"type":"string","types":["string"]}},"types":["object"]}},"$schema":"http://json-schema.org/draft-04/schema#"}>
Raw output
java.lang.AssertionError: JSON schemas MUST match.
Expected: is <{"type":"object","properties":{"name":{"type":"string"}},"definitions":{"Response":{"type":"object","properties":{"id":{"type":"string"}}}},"$schema":"http://json-schema.org/draft-04/schema#"}>
but: was <{"type":"object","properties":{"name":{"type":"string","types":["string"]}},"types":["object"],"definitions":{"Response":{"type":"object","properties":{"id":{"type":"string","types":["string"]}},"types":["object"]}},"$schema":"http://json-schema.org/draft-04/schema#"}>
at org.hamcrest.MatcherAssert.assertThat(MatcherAssert.java:20)
at com.ebay.openapi.export.jsonschema.OpenApiToJsonSchemaTest.testRequestInlineSchema(OpenApiToJsonSchemaTest.java:261)
github-actions / Test Report
OpenApiToJsonSchemaTest.testRequestSchema
JSON schemas MUST match.
Expected: is <{"type":"object","properties":{"name":{"type":"string"}},"definitions":{"Request":{"type":"object","properties":{"name":{"type":"string"}}},"Response":{"type":"object","properties":{"id":{"type":"string"}}}},"$schema":"http://json-schema.org/draft-04/schema#"}>
but: was <{"type":"object","properties":{"name":{"type":"string","types":["string"]}},"types":["object"],"definitions":{"Request":{"type":"object","properties":{"name":{"type":"string","types":["string"]}},"types":["object"]},"Response":{"type":"object","properties":{"id":{"type":"string","types":["string"]}},"types":["object"]}},"$schema":"http://json-schema.org/draft-04/schema#"}>
Raw output
java.lang.AssertionError: JSON schemas MUST match.
Expected: is <{"type":"object","properties":{"name":{"type":"string"}},"definitions":{"Request":{"type":"object","properties":{"name":{"type":"string"}}},"Response":{"type":"object","properties":{"id":{"type":"string"}}}},"$schema":"http://json-schema.org/draft-04/schema#"}>
but: was <{"type":"object","properties":{"name":{"type":"string","types":["string"]}},"types":["object"],"definitions":{"Request":{"type":"object","properties":{"name":{"type":"string","types":["string"]}},"types":["object"]},"Response":{"type":"object","properties":{"id":{"type":"string","types":["string"]}},"types":["object"]}},"$schema":"http://json-schema.org/draft-04/schema#"}>
at org.hamcrest.MatcherAssert.assertThat(MatcherAssert.java:20)
at com.ebay.openapi.export.jsonschema.OpenApiToJsonSchemaTest.testRequestSchema(OpenApiToJsonSchemaTest.java:247)
github-actions / Test Report
OpenApiToJsonSchemaTest.testRequestSchemaIgnoresStatusCode
JSON schemas MUST match.
Expected: is <{"type":"object","properties":{"name":{"type":"string"}},"definitions":{"Request":{"type":"object","properties":{"name":{"type":"string"}}},"Response":{"type":"object","properties":{"id":{"type":"string"}}}},"$schema":"http://json-schema.org/draft-04/schema#"}>
but: was <{"type":"object","properties":{"name":{"type":"string","types":["string"]}},"types":["object"],"definitions":{"Request":{"type":"object","properties":{"name":{"type":"string","types":["string"]}},"types":["object"]},"Response":{"type":"object","properties":{"id":{"type":"string","types":["string"]}},"types":["object"]}},"$schema":"http://json-schema.org/draft-04/schema#"}>
Raw output
java.lang.AssertionError: JSON schemas MUST match.
Expected: is <{"type":"object","properties":{"name":{"type":"string"}},"definitions":{"Request":{"type":"object","properties":{"name":{"type":"string"}}},"Response":{"type":"object","properties":{"id":{"type":"string"}}}},"$schema":"http://json-schema.org/draft-04/schema#"}>
but: was <{"type":"object","properties":{"name":{"type":"string","types":["string"]}},"types":["object"],"definitions":{"Request":{"type":"object","properties":{"name":{"type":"string","types":["string"]}},"types":["object"]},"Response":{"type":"object","properties":{"id":{"type":"string","types":["string"]}},"types":["object"]}},"$schema":"http://json-schema.org/draft-04/schema#"}>
at org.hamcrest.MatcherAssert.assertThat(MatcherAssert.java:20)
at com.ebay.openapi.export.jsonschema.OpenApiToJsonSchemaTest.testRequestSchemaIgnoresStatusCode(OpenApiToJsonSchemaTest.java:254)
github-actions / Test Report
OpenApiToJsonSchemaTest.testRequestSchemaWithoutAdditionalProperties
JSON schemas MUST match.
Expected: is <{"type":"object","properties":{"name":{"type":"string"}},"definitions":{"Request":{"type":"object","properties":{"name":{"type":"string"}},"additionalProperties":false},"Response":{"type":"object","properties":{"id":{"type":"string"}},"additionalProperties":false}},"$schema":"http://json-schema.org/draft-04/schema#","additionalProperties":false}>
but: was <{"type":"object","properties":{"name":{"type":"string","types":["string"]}},"types":["object"],"definitions":{"Response":{"type":"object","properties":{"id":{"type":"string","types":["string"]}},"types":["object"],"additionalProperties":false},"Request":{"type":"object","properties":{"name":{"type":"string","types":["string"]}},"types":["object"],"additionalProperties":false}},"$schema":"http://json-schema.org/draft-04/schema#","additionalProperties":false}>
Raw output
java.lang.AssertionError: JSON schemas MUST match.
Expected: is <{"type":"object","properties":{"name":{"type":"string"}},"definitions":{"Request":{"type":"object","properties":{"name":{"type":"string"}},"additionalProperties":false},"Response":{"type":"object","properties":{"id":{"type":"string"}},"additionalProperties":false}},"$schema":"http://json-schema.org/draft-04/schema#","additionalProperties":false}>
but: was <{"type":"object","properties":{"name":{"type":"string","types":["string"]}},"types":["object"],"definitions":{"Response":{"type":"object","properties":{"id":{"type":"string","types":["string"]}},"types":["object"],"additionalProperties":false},"Request":{"type":"object","properties":{"name":{"type":"string","types":["string"]}},"types":["object"],"additionalProperties":false}},"$schema":"http://json-schema.org/draft-04/schema#","additionalProperties":false}>
at org.hamcrest.MatcherAssert.assertThat(MatcherAssert.java:20)
at com.ebay.openapi.export.jsonschema.OpenApiToJsonSchemaTest.testRequestSchemaWithoutAdditionalProperties(OpenApiToJsonSchemaTest.java:268)
github-actions / Test Report
OpenApiToJsonSchemaTest.testYamlWith400ResponseSchema
JSON schemas MUST match.
Expected: is <{"type":"object","properties":{"hello":{"type":"string"}},"definitions":{"Response":{"type":"object","properties":{"hello":{"type":"string"}}}},"$schema":"http://json-schema.org/draft-04/schema#"}>
but: was <{"type":"object","properties":{"hello":{"type":"string","types":["string"]}},"types":["object"],"definitions":{"Response":{"type":"object","properties":{"hello":{"type":"string","types":["string"]}},"types":["object"]}},"$schema":"http://json-schema.org/draft-04/schema#"}>
Raw output
java.lang.AssertionError: JSON schemas MUST match.
Expected: is <{"type":"object","properties":{"hello":{"type":"string"}},"definitions":{"Response":{"type":"object","properties":{"hello":{"type":"string"}}}},"$schema":"http://json-schema.org/draft-04/schema#"}>
but: was <{"type":"object","properties":{"hello":{"type":"string","types":["string"]}},"types":["object"],"definitions":{"Response":{"type":"object","properties":{"hello":{"type":"string","types":["string"]}},"types":["object"]}},"$schema":"http://json-schema.org/draft-04/schema#"}>
at org.hamcrest.MatcherAssert.assertThat(MatcherAssert.java:20)
at com.ebay.openapi.export.jsonschema.OpenApiToJsonSchemaTest.testYamlWith400ResponseSchema(OpenApiToJsonSchemaTest.java:219)
github-actions / Test Report
OpenApiToJsonSchemaTest.testYamlWith400ResposneSchemaAndAdditionalPropertiesFalse
JSON schemas MUST match.
Expected: is <{"type":"object","properties":{"hello":{"type":"string"}},"definitions":{"Response":{"type":"object","properties":{"hello":{"type":"string"}},"additionalProperties":false}},"$schema":"http://json-schema.org/draft-04/schema#","additionalProperties":false}>
but: was <{"type":"object","properties":{"hello":{"type":"string","types":["string"]}},"types":["object"],"definitions":{"Response":{"type":"object","properties":{"hello":{"type":"string","types":["string"]}},"types":["object"],"additionalProperties":false}},"$schema":"http://json-schema.org/draft-04/schema#","additionalProperties":false}>
Raw output
java.lang.AssertionError: JSON schemas MUST match.
Expected: is <{"type":"object","properties":{"hello":{"type":"string"}},"definitions":{"Response":{"type":"object","properties":{"hello":{"type":"string"}},"additionalProperties":false}},"$schema":"http://json-schema.org/draft-04/schema#","additionalProperties":false}>
but: was <{"type":"object","properties":{"hello":{"type":"string","types":["string"]}},"types":["object"],"definitions":{"Response":{"type":"object","properties":{"hello":{"type":"string","types":["string"]}},"types":["object"],"additionalProperties":false}},"$schema":"http://json-schema.org/draft-04/schema#","additionalProperties":false}>
at org.hamcrest.MatcherAssert.assertThat(MatcherAssert.java:20)
at com.ebay.openapi.export.jsonschema.OpenApiToJsonSchemaTest.testYamlWith400ResposneSchemaAndAdditionalPropertiesFalse(OpenApiToJsonSchemaTest.java:226)
github-actions / Test Report
OpenApiToJsonSchemaTest.yamlWithAllOf
JSON schemas MUST match.
Expected: is <{"allOf":[{"$ref":"#/definitions/Root"},{"type":"object","properties":{"three":{"type":"boolean"}}}],"definitions":{"Response":{"allOf":[{"$ref":"#/definitions/Root"},{"type":"object","properties":{"three":{"type":"boolean"}}}]},"Root":{"type":"object","properties":{"one":{"type":"integer"},"two":{"type":"string"}}}},"$schema":"http://json-schema.org/draft-04/schema#"}>
but: was <{"allOf":[{"$ref":"#/definitions/Root"},{"type":"object","properties":{"three":{"type":"boolean","types":["boolean"]}},"types":["object"]}],"definitions":{"Response":{"allOf":[{"$ref":"#/definitions/Root"},{"type":"object","properties":{"three":{"type":"boolean","types":["boolean"]}},"types":["object"]}]},"Root":{"type":"object","properties":{"one":{"type":"integer","types":["integer"]},"two":{"type":"string","types":["string"]}},"types":["object"]}},"$schema":"http://json-schema.org/draft-04/schema#"}>
Raw output
java.lang.AssertionError: JSON schemas MUST match.
Expected: is <{"allOf":[{"$ref":"#/definitions/Root"},{"type":"object","properties":{"three":{"type":"boolean"}}}],"definitions":{"Response":{"allOf":[{"$ref":"#/definitions/Root"},{"type":"object","properties":{"three":{"type":"boolean"}}}]},"Root":{"type":"object","properties":{"one":{"type":"integer"},"two":{"type":"string"}}}},"$schema":"http://json-schema.org/draft-04/schema#"}>
but: was <{"allOf":[{"$ref":"#/definitions/Root"},{"type":"object","properties":{"three":{"type":"boolean","types":["boolean"]}},"types":["object"]}],"definitions":{"Response":{"allOf":[{"$ref":"#/definitions/Root"},{"type":"object","properties":{"three":{"type":"boolean","types":["boolean"]}},"types":["object"]}]},"Root":{"type":"object","properties":{"one":{"type":"integer","types":["integer"]},"two":{"type":"string","types":["string"]}},"types":["object"]}},"$schema":"http://json-schema.org/draft-04/schema#"}>
at org.hamcrest.MatcherAssert.assertThat(MatcherAssert.java:20)
at com.ebay.openapi.export.jsonschema.OpenApiToJsonSchemaTest.yamlWithAllOf(OpenApiToJsonSchemaTest.java:46)
github-actions / Test Report
OpenApiToJsonSchemaTest.yamlWithAllOfDisallowAdditionalProperties
JSON schemas MUST match.
Expected: is <{"required":["three","one","two"],"type":"object","properties":{"three":{"type":"boolean"},"one":{"type":"integer"},"two":{"type":"string"}},"definitions":{"Response":{"required":["three","one","two"],"type":"object","properties":{"three":{"type":"boolean"},"one":{"type":"integer"},"two":{"type":"string"}},"additionalProperties":false},"Root":{"required":["one","two"],"type":"object","properties":{"one":{"type":"integer"},"two":{"type":"string"}},"additionalProperties":false}},"$schema":"http://json-schema.org/draft-04/schema#","additionalProperties":false}>
but: was <{"required":["three","one","two"],"type":"object","properties":{"three":{"type":"boolean","types":["boolean"]},"one":{"type":"integer","types":["integer"]},"two":{"type":"string","types":["string"]}},"types":["object"],"definitions":{"Response":{"required":["three","one","two"],"type":"object","properties":{"three":{"type":"boolean","types":["boolean"]},"one":{"type":"integer","types":["integer"]},"two":{"type":"string","types":["string"]}},"types":["object"],"additionalProperties":false},"Root":{"required":["one","two"],"type":"object","properties":{"one":{"type":"integer","types":["integer"]},"two":{"type":"string","types":["string"]}},"types":["object"],"additionalProperties":false}},"$schema":"http://json-schema.org/draft-04/schema#","additionalProperties":false}>
Raw output
java.lang.AssertionError: JSON schemas MUST match.
Expected: is <{"required":["three","one","two"],"type":"object","properties":{"three":{"type":"boolean"},"one":{"type":"integer"},"two":{"type":"string"}},"definitions":{"Response":{"required":["three","one","two"],"type":"object","properties":{"three":{"type":"boolean"},"one":{"type":"integer"},"two":{"type":"string"}},"additionalProperties":false},"Root":{"required":["one","two"],"type":"object","properties":{"one":{"type":"integer"},"two":{"type":"string"}},"additionalProperties":false}},"$schema":"http://json-schema.org/draft-04/schema#","additionalProperties":false}>
but: was <{"required":["three","one","two"],"type":"object","properties":{"three":{"type":"boolean","types":["boolean"]},"one":{"type":"integer","types":["integer"]},"two":{"type":"string","types":["string"]}},"types":["object"],"definitions":{"Response":{"required":["three","one","two"],"type":"object","properties":{"three":{"type":"boolean","types":["boolean"]},"one":{"type":"integer","types":["integer"]},"two":{"type":"string","types":["string"]}},"types":["object"],"additionalProperties":false},"Root":{"required":["one","two"],"type":"object","properties":{"one":{"type":"integer","types":["integer"]},"two":{"type":"string","types":["string"]}},"types":["object"],"additionalProperties":false}},"$schema":"http://json-schema.org/draft-04/schema#","additionalProperties":false}>
at org.hamcrest.MatcherAssert.assertThat(MatcherAssert.java:20)
at com.ebay.openapi.export.jsonschema.OpenApiToJsonSchemaTest.yamlWithAllOfDisallowAdditionalProperties(OpenApiToJsonSchemaTest.java:54)
github-actions / Test Report
OpenApiToJsonSchemaTest.yamlWithAnyOf
JSON schemas MUST match.
Expected: is <{"anyOf":[{"$ref":"#/definitions/Apple"},{"$ref":"#/definitions/Banana"},{"$ref":"#/definitions/Pear"}],"definitions":{"Apple":{"type":"object","properties":{"seeds":{"type":"integer"},"flavor":{"type":"string"}}},"Banana":{"type":"object","properties":{"color":{"type":"string"},"size":{"type":"integer"}}},"Pear":{"type":"object","properties":{"ripe":{"type":"boolean"},"organic":{"type":"boolean"}}}},"$schema":"http://json-schema.org/draft-04/schema#"}>
but: was <{"anyOf":[{"$ref":"#/definitions/Apple"},{"$ref":"#/definitions/Banana"},{"$ref":"#/definitions/Pear"}],"definitions":{"Apple":{"type":"object","properties":{"seeds":{"type":"integer","types":["integer"]},"flavor":{"type":"string","types":["string"]}},"types":["object"]},"Banana":{"type":"object","properties":{"color":{"type":"string","types":["string"]},"size":{"type":"integer","types":["integer"]}},"types":["object"]},"Pear":{"type":"object","properties":{"ripe":{"type":"boolean","types":["boolean"]},"organic":{"type":"boolean","types":["boolean"]}},"types":["object"]}},"$schema":"http://json-schema.org/draft-04/schema#"}>
Raw output
java.lang.AssertionError: JSON schemas MUST match.
Expected: is <{"anyOf":[{"$ref":"#/definitions/Apple"},{"$ref":"#/definitions/Banana"},{"$ref":"#/definitions/Pear"}],"definitions":{"Apple":{"type":"object","properties":{"seeds":{"type":"integer"},"flavor":{"type":"string"}}},"Banana":{"type":"object","properties":{"color":{"type":"string"},"size":{"type":"integer"}}},"Pear":{"type":"object","properties":{"ripe":{"type":"boolean"},"organic":{"type":"boolean"}}}},"$schema":"http://json-schema.org/draft-04/schema#"}>
but: was <{"anyOf":[{"$ref":"#/definitions/Apple"},{"$ref":"#/definitions/Banana"},{"$ref":"#/definitions/Pear"}],"definitions":{"Apple":{"type":"object","properties":{"seeds":{"type":"integer","types":["integer"]},"flavor":{"type":"string","types":["string"]}},"types":["object"]},"Banana":{"type":"object","properties":{"color":{"type":"string","types":["string"]},"size":{"type":"integer","types":["integer"]}},"types":["object"]},"Pear":{"type":"object","properties":{"ripe":{"type":"boolean","types":["boolean"]},"organic":{"type":"boolean","types":["boolean"]}},"types":["object"]}},"$schema":"http://json-schema.org/draft-04/schema#"}>
at org.hamcrest.MatcherAssert.assertThat(MatcherAssert.java:20)
at com.ebay.openapi.export.jsonschema.OpenApiToJsonSchemaTest.yamlWithAnyOf(OpenApiToJsonSchemaTest.java:94)
github-actions / Test Report
OpenApiToJsonSchemaTest.yamlWithAnyOfComposites
JSON schemas MUST match.
Expected: is <{"type":"object","anyOf":[{"$ref":"#/definitions/Apple"},{"$ref":"#/definitions/Banana"},{"$ref":"#/definitions/Manzana"}],"definitions":{"Response":{"type":"object","anyOf":[{"$ref":"#/definitions/Apple"},{"$ref":"#/definitions/Banana"},{"$ref":"#/definitions/Manzana"}]},"Apple":{"type":"object","properties":{"seeds":{"type":"integer"},"flavor":{"type":"string"},"price":{"type":"number"}},"additionalProperties":false},"Fruit":{"type":"object","properties":{"price":{"type":"number"}},"additionalProperties":false},"Manzana":{"$ref":"#/definitions/Apple"},"Banana":{"type":"object","properties":{"color":{"type":"string"},"size":{"type":"integer"},"price":{"type":"number"}},"additionalProperties":false}},"$schema":"http://json-schema.org/draft-04/schema#"}>
but: was <{"type":"object","anyOf":[{"$ref":"#/definitions/Apple"},{"$ref":"#/definitions/Banana"},{"$ref":"#/definitions/Manzana"}],"definitions":{"Response":{"type":"object","anyOf":[{"$ref":"#/definitions/Apple"},{"$ref":"#/definitions/Banana"},{"$ref":"#/definitions/Manzana"}]},"Apple":{"type":"object","properties":{"seeds":{"type":"integer","types":["integer"]},"flavor":{"type":"string","types":["string"]},"price":{"type":"number","types":["number"]}},"types":["object"],"additionalProperties":false},"Fruit":{"type":"object","properties":{"price":{"type":"number","types":["number"]}},"types":["object"],"additionalProperties":false},"Manzana":{"$ref":"#/definitions/Apple"},"Banana":{"type":"object","properties":{"color":{"type":"string","types":["string"]},"size":{"type":"integer","types":["integer"]},"price":{"type":"number","types":["number"]}},"types":["object"],"additionalProperties":false}},"$schema":"http://json-schema.org/draft-04/schema#"}>
Raw output
java.lang.AssertionError: JSON schemas MUST match.
Expected: is <{"type":"object","anyOf":[{"$ref":"#/definitions/Apple"},{"$ref":"#/definitions/Banana"},{"$ref":"#/definitions/Manzana"}],"definitions":{"Response":{"type":"object","anyOf":[{"$ref":"#/definitions/Apple"},{"$ref":"#/definitions/Banana"},{"$ref":"#/definitions/Manzana"}]},"Apple":{"type":"object","properties":{"seeds":{"type":"integer"},"flavor":{"type":"string"},"price":{"type":"number"}},"additionalProperties":false},"Fruit":{"type":"object","properties":{"price":{"type":"number"}},"additionalProperties":false},"Manzana":{"$ref":"#/definitions/Apple"},"Banana":{"type":"object","properties":{"color":{"type":"string"},"size":{"type":"integer"},"price":{"type":"number"}},"additionalProperties":false}},"$schema":"http://json-schema.org/draft-04/schema#"}>
but: was <{"type":"object","anyOf":[{"$ref":"#/definitions/Apple"},{"$ref":"#/definitions/Banana"},{"$ref":"#/definitions/Manzana"}],"definitions":{"Response":{"type":"object","anyOf":[{"$ref":"#/definitions/Apple"},{"$ref":"#/definitions/Banana"},{"$ref":"#/definitions/Manzana"}]},"Apple":{"type":"object","properties":{"seeds":{"type":"integer","types":["integer"]},"flavor":{"type":"string","types":["string"]},"price":{"type":"number","types":["number"]}},"types":["object"],"additionalProperties":false},"Fruit":{"type":"object","properties":{"price":{"type":"number","types":["number"]}},"types":["object"],"additionalProperties":false},"Manzana":{"$ref":"#/definitions/Apple"},"Banana":{"type":"object","properties":{"color":{"type":"string","types":["string"]},"size":{"type":"integer","types":["integer"]},"price":{"type":"number","types":["number"]}},"types":["object"],"additionalProperties":false}},"$schema":"http://json-schema.org/draft-04/schema#"}>
at org.hamcrest.MatcherAssert.assertThat(MatcherAssert.java:20)
at com.ebay.openapi.export.jsonschema.OpenApiToJsonSchemaTest.yamlWithAnyOfComposites(OpenApiToJsonSchemaTest.java:102)
github-actions / Test Report
OpenApiToJsonSchemaTest.yamlWithAnyOfOnProperty
JSON schemas MUST match.
Expected: is <{"type":"object","properties":{"seeds":{"anyOf":[{"$ref":"#/definitions/option1"},{"$ref":"#/definitions/option2"}]}},"definitions":{"Apple":{"type":"object","properties":{"seeds":{"anyOf":[{"$ref":"#/definitions/option1"},{"$ref":"#/definitions/option2"}]}}},"option1":{"type":"object","properties":{"first":{"type":"string"},"second":{"type":"integer"}}},"option2":{"type":"object","properties":{"first":{"type":"string"},"second":{"type":"boolean"}}}},"$schema":"http://json-schema.org/draft-04/schema#"}>
but: was <{"type":"object","properties":{"seeds":{"anyOf":[{"$ref":"#/definitions/option1"},{"$ref":"#/definitions/option2"}]}},"types":["object"],"definitions":{"Apple":{"type":"object","properties":{"seeds":{"anyOf":[{"$ref":"#/definitions/option1"},{"$ref":"#/definitions/option2"}]}},"types":["object"]},"option1":{"type":"object","properties":{"first":{"type":"string","types":["string"]},"second":{"type":"integer","types":["integer"]}},"types":["object"]},"option2":{"type":"object","properties":{"first":{"type":"string","types":["string"]},"second":{"type":"boolean","types":["boolean"]}},"types":["object"]}},"$schema":"http://json-schema.org/draft-04/schema#"}>
Raw output
java.lang.AssertionError: JSON schemas MUST match.
Expected: is <{"type":"object","properties":{"seeds":{"anyOf":[{"$ref":"#/definitions/option1"},{"$ref":"#/definitions/option2"}]}},"definitions":{"Apple":{"type":"object","properties":{"seeds":{"anyOf":[{"$ref":"#/definitions/option1"},{"$ref":"#/definitions/option2"}]}}},"option1":{"type":"object","properties":{"first":{"type":"string"},"second":{"type":"integer"}}},"option2":{"type":"object","properties":{"first":{"type":"string"},"second":{"type":"boolean"}}}},"$schema":"http://json-schema.org/draft-04/schema#"}>
but: was <{"type":"object","properties":{"seeds":{"anyOf":[{"$ref":"#/definitions/option1"},{"$ref":"#/definitions/option2"}]}},"types":["object"],"definitions":{"Apple":{"type":"object","properties":{"seeds":{"anyOf":[{"$ref":"#/definitions/option1"},{"$ref":"#/definitions/option2"}]}},"types":["object"]},"option1":{"type":"object","properties":{"first":{"type":"string","types":["string"]},"second":{"type":"integer","types":["integer"]}},"types":["object"]},"option2":{"type":"object","properties":{"first":{"type":"string","types":["string"]},"second":{"type":"boolean","types":["boolean"]}},"types":["object"]}},"$schema":"http://json-schema.org/draft-04/schema#"}>
at org.hamcrest.MatcherAssert.assertThat(MatcherAssert.java:20)
at com.ebay.openapi.export.jsonschema.OpenApiToJsonSchemaTest.yamlWithAnyOfOnProperty(OpenApiToJsonSchemaTest.java:110)
github-actions / Test Report
OpenApiToJsonSchemaTest.yamlWithArray
JSON schemas MUST match.
Expected: is <{"type":"object","properties":{"seeds":{"type":"integer"},"flavors":{"type":"array","items":{"type":"string"}}},"definitions":{"Apple":{"type":"object","properties":{"seeds":{"type":"integer"},"flavors":{"type":"array","items":{"type":"string"}}}}},"$schema":"http://json-schema.org/draft-04/schema#"}>
but: was <{"type":"object","properties":{"seeds":{"type":"integer","types":["integer"]},"flavors":{"type":"array","items":{"type":"string","types":["string"]},"types":["array"]}},"types":["object"],"definitions":{"Apple":{"type":"object","properties":{"seeds":{"type":"integer","types":["integer"]},"flavors":{"type":"array","items":{"type":"string","types":["string"]},"types":["array"]}},"types":["object"]}},"$schema":"http://json-schema.org/draft-04/schema#"}>
Raw output
java.lang.AssertionError: JSON schemas MUST match.
Expected: is <{"type":"object","properties":{"seeds":{"type":"integer"},"flavors":{"type":"array","items":{"type":"string"}}},"definitions":{"Apple":{"type":"object","properties":{"seeds":{"type":"integer"},"flavors":{"type":"array","items":{"type":"string"}}}}},"$schema":"http://json-schema.org/draft-04/schema#"}>
but: was <{"type":"object","properties":{"seeds":{"type":"integer","types":["integer"]},"flavors":{"type":"array","items":{"type":"string","types":["string"]},"types":["array"]}},"types":["object"],"definitions":{"Apple":{"type":"object","properties":{"seeds":{"type":"integer","types":["integer"]},"flavors":{"type":"array","items":{"type":"string","types":["string"]},"types":["array"]}},"types":["object"]}},"$schema":"http://json-schema.org/draft-04/schema#"}>
at org.hamcrest.MatcherAssert.assertThat(MatcherAssert.java:20)
at com.ebay.openapi.export.jsonschema.OpenApiToJsonSchemaTest.yamlWithArray(OpenApiToJsonSchemaTest.java:118)
github-actions / Test Report
OpenApiToJsonSchemaTest.yamlWithArrayProperties
JSON schemas MUST match.
Expected: is <{"type":"object","properties":{"colors":{"maxItems":4,"minItems":2,"uniqueItems":true,"type":"array","items":{"type":"string"}}},"definitions":{"Apple":{"type":"object","properties":{"colors":{"maxItems":4,"minItems":2,"uniqueItems":true,"type":"array","items":{"type":"string"}}}}},"$schema":"http://json-schema.org/draft-04/schema#"}>
but: was <{"type":"object","properties":{"colors":{"maxItems":4,"minItems":2,"uniqueItems":true,"type":"array","items":{"type":"string","types":["string"]},"types":["array"]}},"types":["object"],"definitions":{"Apple":{"type":"object","properties":{"colors":{"maxItems":4,"minItems":2,"uniqueItems":true,"type":"array","items":{"type":"string","types":["string"]},"types":["array"]}},"types":["object"]}},"$schema":"http://json-schema.org/draft-04/schema#"}>
Raw output
java.lang.AssertionError: JSON schemas MUST match.
Expected: is <{"type":"object","properties":{"colors":{"maxItems":4,"minItems":2,"uniqueItems":true,"type":"array","items":{"type":"string"}}},"definitions":{"Apple":{"type":"object","properties":{"colors":{"maxItems":4,"minItems":2,"uniqueItems":true,"type":"array","items":{"type":"string"}}}}},"$schema":"http://json-schema.org/draft-04/schema#"}>
but: was <{"type":"object","properties":{"colors":{"maxItems":4,"minItems":2,"uniqueItems":true,"type":"array","items":{"type":"string","types":["string"]},"types":["array"]}},"types":["object"],"definitions":{"Apple":{"type":"object","properties":{"colors":{"maxItems":4,"minItems":2,"uniqueItems":true,"type":"array","items":{"type":"string","types":["string"]},"types":["array"]}},"types":["object"]}},"$schema":"http://json-schema.org/draft-04/schema#"}>
at org.hamcrest.MatcherAssert.assertThat(MatcherAssert.java:20)
at com.ebay.openapi.export.jsonschema.OpenApiToJsonSchemaTest.yamlWithArrayProperties(OpenApiToJsonSchemaTest.java:204)
github-actions / Test Report
OpenApiToJsonSchemaTest.yamlWithIntegerProperties
JSON schemas MUST match.
Expected: is "{\n \"type\" : \"object\",\n \"properties\" : {\n \"seeds\" : {\n \"multipleOf\" : 2,\n \"type\" : \"integer\"\n },\n \"sizeInclusive\" : {\n \"maximum\" : 3,\n \"minimum\" : 1,\n \"type\" : \"integer\"\n },\n \"sizeExclusive\" : {\n \"maximum\" : 3,\n \"exclusiveMaximum\" : true,\n \"minimum\" : 1,\n \"exclusiveMinimum\" : true,\n \"type\" : \"integer\"\n }\n },\n \"definitions\" : {\n \"Apple\" : {\n \"type\" : \"object\",\n \"properties\" : {\n \"seeds\" : {\n \"multipleOf\" : 2,\n \"type\" : \"integer\"\n },\n \"sizeInclusive\" : {\n \"maximum\" : 3,\n \"minimum\" : 1,\n \"type\" : \"integer\"\n },\n \"sizeExclusive\" : {\n \"maximum\" : 3,\n \"exclusiveMaximum\" : true,\n \"minimum\" : 1,\n \"exclusiveMinimum\" : true,\n \"type\" : \"integer\"\n }\n }\n }\n },\n \"$schema\" : \"http://json-schema.org/draft-04/schema#\"\n}"
but: was "{\n \"type\" : \"object\",\n \"properties\" : {\n \"seeds\" : {\n \"multipleOf\" : 2,\n \"type\" : \"integer\",\n \"types\" : [ \"integer\" ]\n },\n \"sizeInclusive\" : {\n \"maximum\" : 3,\n \"minimum\" : 1,\n \"type\" : \"integer\",\n \"types\" : [ \"integer\" ]\n },\n \"sizeExclusive\" : {\n \"maximum\" : 3,\n \"exclusiveMaximum\" : true,\n \"minimum\" : 1,\n \"exclusiveMinimum\" : true,\n \"type\" : \"integer\",\n \"types\" : [ \"integer\" ]\n }\n },\n \"types\" : [ \"object\" ],\n \"definitions\" : {\n \"Apple\" : {\n \"type\" : \"object\",\n \"properties\" : {\n \"seeds\" : {\n \"multipleOf\" : 2,\n \"type\" : \"integer\",\n \"types\" : [ \"integer\" ]\n },\n \"sizeInclusive\" : {\n \"maximum\" : 3,\n \"minimum\" : 1,\n \"type\" : \"integer\",\n \"types\" : [ \"integer\" ]\n },\n \"sizeExclusive\" : {\n \"maximum\" : 3,\n \"exclusiveMaximum\" : true,\n \"minimum\" : 1,\n \"exclusiveMinimum\" : true,\n \"type\" : \"integer\",\n \"types\" : [ \"integer\" ]\n }\n },\n \"types\" : [ \"object\" ]\n }\n },\n \"$schema\" : \"http://json-schema.org/draft-04/schema#\"\n}"
Raw output
java.lang.AssertionError: JSON schemas MUST match.
Expected: is "{\n \"type\" : \"object\",\n \"properties\" : {\n \"seeds\" : {\n \"multipleOf\" : 2,\n \"type\" : \"integer\"\n },\n \"sizeInclusive\" : {\n \"maximum\" : 3,\n \"minimum\" : 1,\n \"type\" : \"integer\"\n },\n \"sizeExclusive\" : {\n \"maximum\" : 3,\n \"exclusiveMaximum\" : true,\n \"minimum\" : 1,\n \"exclusiveMinimum\" : true,\n \"type\" : \"integer\"\n }\n },\n \"definitions\" : {\n \"Apple\" : {\n \"type\" : \"object\",\n \"properties\" : {\n \"seeds\" : {\n \"multipleOf\" : 2,\n \"type\" : \"integer\"\n },\n \"sizeInclusive\" : {\n \"maximum\" : 3,\n \"minimum\" : 1,\n \"type\" : \"integer\"\n },\n \"sizeExclusive\" : {\n \"maximum\" : 3,\n \"exclusiveMaximum\" : true,\n \"minimum\" : 1,\n \"exclusiveMinimum\" : true,\n \"type\" : \"integer\"\n }\n }\n }\n },\n \"$schema\" : \"http://json-schema.org/draft-04/schema#\"\n}"
but: was "{\n \"type\" : \"object\",\n \"properties\" : {\n \"seeds\" : {\n \"multipleOf\" : 2,\n \"type\" : \"integer\",\n \"types\" : [ \"integer\" ]\n },\n \"sizeInclusive\" : {\n \"maximum\" : 3,\n \"minimum\" : 1,\n \"type\" : \"integer\",\n \"types\" : [ \"integer\" ]\n },\n \"sizeExclusive\" : {\n \"maximum\" : 3,\n \"exclusiveMaximum\" : true,\n \"minimum\" : 1,\n \"exclusiveMinimum\" : true,\n \"type\" : \"integer\",\n \"types\" : [ \"integer\" ]\n }\n },\n \"types\" : [ \"object\" ],\n \"definitions\" : {\n \"Apple\" : {\n \"type\" : \"object\",\n \"properties\" : {\n \"seeds\" : {\n \"multipleOf\" : 2,\n \"type\" : \"integer\",\n \"types\" : [ \"integer\" ]\n },\n \"sizeInclusive\" : {\n \"maximum\" : 3,\n \"minimum\" : 1,\n \"type\" : \"integer\",\n \"types\" : [ \"integer\" ]\n },\n \"sizeExclusive\" : {\n \"maximum\" : 3,\n \"exclusiveMaximum\" : true,\n \"minimum\" : 1,\n \"exclusiveMinimum\" : true,\n \"type\" : \"integer\",\n \"types\" : [ \"integer\" ]\n }\n },\n \"types\" : [ \"object\" ]\n }\n },\n \"$schema\" : \"http://json-schema.org/draft-04/schema#\"\n}"
at org.hamcrest.MatcherAssert.assertThat(MatcherAssert.java:20)
at com.ebay.openapi.export.jsonschema.OpenApiToJsonSchemaTest.yamlWithIntegerProperties(OpenApiToJsonSchemaTest.java:138)
github-actions / Test Report
OpenApiToJsonSchemaTest.yamlWithNoRefsInPath
JSON schemas MUST match.
Expected: is <{"type":"object","properties":{"a":{"type":"string"},"b":{"type":"integer"},"c":{"type":"array","items":{"type":"boolean"}}},"definitions":{},"$schema":"http://json-schema.org/draft-04/schema#"}>
but: was <{"type":"object","properties":{"a":{"type":"string","types":["string"]},"b":{"type":"integer","types":["integer"]},"c":{"type":"array","items":{"type":"boolean","types":["boolean"]},"types":["array"]}},"types":["object"],"definitions":{},"$schema":"http://json-schema.org/draft-04/schema#"}>
Raw output
java.lang.AssertionError: JSON schemas MUST match.
Expected: is <{"type":"object","properties":{"a":{"type":"string"},"b":{"type":"integer"},"c":{"type":"array","items":{"type":"boolean"}}},"definitions":{},"$schema":"http://json-schema.org/draft-04/schema#"}>
but: was <{"type":"object","properties":{"a":{"type":"string","types":["string"]},"b":{"type":"integer","types":["integer"]},"c":{"type":"array","items":{"type":"boolean","types":["boolean"]},"types":["array"]}},"types":["object"],"definitions":{},"$schema":"http://json-schema.org/draft-04/schema#"}>
at org.hamcrest.MatcherAssert.assertThat(MatcherAssert.java:20)
at com.ebay.openapi.export.jsonschema.OpenApiToJsonSchemaTest.yamlWithNoRefsInPath(OpenApiToJsonSchemaTest.java:22)
github-actions / Test Report
OpenApiToJsonSchemaTest.yamlWithNullableAdditionalProperties
JSON schemas MUST match.
Expected: is <{"type":"object","properties":{"apple":{"type":"object","additionalProperties":{"type":["string","null"]}}},"definitions":{"Response":{"type":"object","properties":{"apple":{"type":"object","additionalProperties":{"type":["string","null"]}}}}},"$schema":"http://json-schema.org/draft-04/schema#"}>
but: was <{"type":"object","properties":{"apple":{"type":"object","additionalProperties":{"type":["string","null"],"types":["string"]},"types":["object"]}},"types":["object"],"definitions":{"Response":{"type":"object","properties":{"apple":{"type":"object","additionalProperties":{"type":["string","null"],"types":["string"]},"types":["object"]}},"types":["object"]}},"$schema":"http://json-schema.org/draft-04/schema#"}>
Raw output
java.lang.AssertionError: JSON schemas MUST match.
Expected: is <{"type":"object","properties":{"apple":{"type":"object","additionalProperties":{"type":["string","null"]}}},"definitions":{"Response":{"type":"object","properties":{"apple":{"type":"object","additionalProperties":{"type":["string","null"]}}}}},"$schema":"http://json-schema.org/draft-04/schema#"}>
but: was <{"type":"object","properties":{"apple":{"type":"object","additionalProperties":{"type":["string","null"],"types":["string"]},"types":["object"]}},"types":["object"],"definitions":{"Response":{"type":"object","properties":{"apple":{"type":"object","additionalProperties":{"type":["string","null"],"types":["string"]},"types":["object"]}},"types":["object"]}},"$schema":"http://json-schema.org/draft-04/schema#"}>
at org.hamcrest.MatcherAssert.assertThat(MatcherAssert.java:20)
at com.ebay.openapi.export.jsonschema.OpenApiToJsonSchemaTest.yamlWithNullableAdditionalProperties(OpenApiToJsonSchemaTest.java:212)
github-actions / Test Report
OpenApiToJsonSchemaTest.yamlWithObjectProperties
JSON schemas MUST match.
Expected: is <{"maxProperties":3,"minProperties":2,"type":"object","properties":{"name":{"type":"string"},"color":{"type":"string"}},"definitions":{"Apple":{"maxProperties":3,"minProperties":2,"type":"object","properties":{"name":{"type":"string"},"color":{"type":"string"}}}},"$schema":"http://json-schema.org/draft-04/schema#"}>
but: was <{"maxProperties":3,"minProperties":2,"type":"object","properties":{"name":{"type":"string","types":["string"]},"color":{"type":"string","types":["string"]}},"types":["object"],"definitions":{"Apple":{"maxProperties":3,"minProperties":2,"type":"object","properties":{"name":{"type":"string","types":["string"]},"color":{"type":"string","types":["string"]}},"types":["object"]}},"$schema":"http://json-schema.org/draft-04/schema#"}>
Raw output
java.lang.AssertionError: JSON schemas MUST match.
Expected: is <{"maxProperties":3,"minProperties":2,"type":"object","properties":{"name":{"type":"string"},"color":{"type":"string"}},"definitions":{"Apple":{"maxProperties":3,"minProperties":2,"type":"object","properties":{"name":{"type":"string"},"color":{"type":"string"}}}},"$schema":"http://json-schema.org/draft-04/schema#"}>
but: was <{"maxProperties":3,"minProperties":2,"type":"object","properties":{"name":{"type":"string","types":["string"]},"color":{"type":"string","types":["string"]}},"types":["object"],"definitions":{"Apple":{"maxProperties":3,"minProperties":2,"type":"object","properties":{"name":{"type":"string","types":["string"]},"color":{"type":"string","types":["string"]}},"types":["object"]}},"$schema":"http://json-schema.org/draft-04/schema#"}>
at org.hamcrest.MatcherAssert.assertThat(MatcherAssert.java:20)
at com.ebay.openapi.export.jsonschema.OpenApiToJsonSchemaTest.yamlWithObjectProperties(OpenApiToJsonSchemaTest.java:186)
github-actions / Test Report
OpenApiToJsonSchemaTest.yamlWithOneOf
JSON schemas MUST match.
Expected: is <{"oneOf":[{"$ref":"#/definitions/Apple"},{"$ref":"#/definitions/Banana"},{"$ref":"#/definitions/Pear"}],"definitions":{"Apple":{"type":"object","properties":{"seeds":{"type":"integer"},"flavor":{"type":"string"}}},"Banana":{"type":"object","properties":{"color":{"type":"string"},"size":{"type":"integer"}}},"Pear":{"type":"object","properties":{"ripe":{"type":"boolean"},"organic":{"type":"boolean"}}}},"$schema":"http://json-schema.org/draft-04/schema#"}>
but: was <{"oneOf":[{"$ref":"#/definitions/Apple"},{"$ref":"#/definitions/Banana"},{"$ref":"#/definitions/Pear"}],"definitions":{"Apple":{"type":"object","properties":{"seeds":{"type":"integer","types":["integer"]},"flavor":{"type":"string","types":["string"]}},"types":["object"]},"Banana":{"type":"object","properties":{"color":{"type":"string","types":["string"]},"size":{"type":"integer","types":["integer"]}},"types":["object"]},"Pear":{"type":"object","properties":{"ripe":{"type":"boolean","types":["boolean"]},"organic":{"type":"boolean","types":["boolean"]}},"types":["object"]}},"$schema":"http://json-schema.org/draft-04/schema#"}>
Raw output
java.lang.AssertionError: JSON schemas MUST match.
Expected: is <{"oneOf":[{"$ref":"#/definitions/Apple"},{"$ref":"#/definitions/Banana"},{"$ref":"#/definitions/Pear"}],"definitions":{"Apple":{"type":"object","properties":{"seeds":{"type":"integer"},"flavor":{"type":"string"}}},"Banana":{"type":"object","properties":{"color":{"type":"string"},"size":{"type":"integer"}}},"Pear":{"type":"object","properties":{"ripe":{"type":"boolean"},"organic":{"type":"boolean"}}}},"$schema":"http://json-schema.org/draft-04/schema#"}>
but: was <{"oneOf":[{"$ref":"#/definitions/Apple"},{"$ref":"#/definitions/Banana"},{"$ref":"#/definitions/Pear"}],"definitions":{"Apple":{"type":"object","properties":{"seeds":{"type":"integer","types":["integer"]},"flavor":{"type":"string","types":["string"]}},"types":["object"]},"Banana":{"type":"object","properties":{"color":{"type":"string","types":["string"]},"size":{"type":"integer","types":["integer"]}},"types":["object"]},"Pear":{"type":"object","properties":{"ripe":{"type":"boolean","types":["boolean"]},"organic":{"type":"boolean","types":["boolean"]}},"types":["object"]}},"$schema":"http://json-schema.org/draft-04/schema#"}>
at org.hamcrest.MatcherAssert.assertThat(MatcherAssert.java:20)
at com.ebay.openapi.export.jsonschema.OpenApiToJsonSchemaTest.yamlWithOneOf(OpenApiToJsonSchemaTest.java:62)
github-actions / Test Report
OpenApiToJsonSchemaTest.yamlWithOneOfComposites
JSON schemas MUST match.
Expected: is <{"type":"object","oneOf":[{"$ref":"#/definitions/Apple"},{"$ref":"#/definitions/Banana"},{"$ref":"#/definitions/Manzana"}],"definitions":{"Response":{"type":"object","oneOf":[{"$ref":"#/definitions/Apple"},{"$ref":"#/definitions/Banana"},{"$ref":"#/definitions/Manzana"}]},"Apple":{"type":"object","properties":{"seeds":{"type":"integer"},"flavor":{"type":"string"},"price":{"type":"number"}},"additionalProperties":false},"Fruit":{"type":"object","properties":{"price":{"type":"number"}},"additionalProperties":false},"Manzana":{"$ref":"#/definitions/Apple"},"Banana":{"type":"object","properties":{"color":{"type":"string"},"size":{"type":"integer"},"price":{"type":"number"}},"additionalProperties":false}},"$schema":"http://json-schema.org/draft-04/schema#"}>
but: was <{"type":"object","oneOf":[{"$ref":"#/definitions/Apple"},{"$ref":"#/definitions/Banana"},{"$ref":"#/definitions/Manzana"}],"definitions":{"Response":{"type":"object","oneOf":[{"$ref":"#/definitions/Apple"},{"$ref":"#/definitions/Banana"},{"$ref":"#/definitions/Manzana"}]},"Apple":{"type":"object","properties":{"seeds":{"type":"integer","types":["integer"]},"flavor":{"type":"string","types":["string"]},"price":{"type":"number","types":["number"]}},"types":["object"],"additionalProperties":false},"Fruit":{"type":"object","properties":{"price":{"type":"number","types":["number"]}},"types":["object"],"additionalProperties":false},"Manzana":{"$ref":"#/definitions/Apple"},"Banana":{"type":"object","properties":{"color":{"type":"string","types":["string"]},"size":{"type":"integer","types":["integer"]},"price":{"type":"number","types":["number"]}},"types":["object"],"additionalProperties":false}},"$schema":"http://json-schema.org/draft-04/schema#"}>
Raw output
java.lang.AssertionError: JSON schemas MUST match.
Expected: is <{"type":"object","oneOf":[{"$ref":"#/definitions/Apple"},{"$ref":"#/definitions/Banana"},{"$ref":"#/definitions/Manzana"}],"definitions":{"Response":{"type":"object","oneOf":[{"$ref":"#/definitions/Apple"},{"$ref":"#/definitions/Banana"},{"$ref":"#/definitions/Manzana"}]},"Apple":{"type":"object","properties":{"seeds":{"type":"integer"},"flavor":{"type":"string"},"price":{"type":"number"}},"additionalProperties":false},"Fruit":{"type":"object","properties":{"price":{"type":"number"}},"additionalProperties":false},"Manzana":{"$ref":"#/definitions/Apple"},"Banana":{"type":"object","properties":{"color":{"type":"string"},"size":{"type":"integer"},"price":{"type":"number"}},"additionalProperties":false}},"$schema":"http://json-schema.org/draft-04/schema#"}>
but: was <{"type":"object","oneOf":[{"$ref":"#/definitions/Apple"},{"$ref":"#/definitions/Banana"},{"$ref":"#/definitions/Manzana"}],"definitions":{"Response":{"type":"object","oneOf":[{"$ref":"#/definitions/Apple"},{"$ref":"#/definitions/Banana"},{"$ref":"#/definitions/Manzana"}]},"Apple":{"type":"object","properties":{"seeds":{"type":"integer","types":["integer"]},"flavor":{"type":"string","types":["string"]},"price":{"type":"number","types":["number"]}},"types":["object"],"additionalProperties":false},"Fruit":{"type":"object","properties":{"price":{"type":"number","types":["number"]}},"types":["object"],"additionalProperties":false},"Manzana":{"$ref":"#/definitions/Apple"},"Banana":{"type":"object","properties":{"color":{"type":"string","types":["string"]},"size":{"type":"integer","types":["integer"]},"price":{"type":"number","types":["number"]}},"types":["object"],"additionalProperties":false}},"$schema":"http://json-schema.org/draft-04/schema#"}>
at org.hamcrest.MatcherAssert.assertThat(MatcherAssert.java:20)
at com.ebay.openapi.export.jsonschema.OpenApiToJsonSchemaTest.yamlWithOneOfComposites(OpenApiToJsonSchemaTest.java:86)
github-actions / Test Report
OpenApiToJsonSchemaTest.yamlWithOneOfOnProperty
JSON schemas MUST match.
Expected: is <{"type":"object","properties":{"seeds":{"oneOf":[{"type":"integer"},{"type":"string"}]}},"definitions":{"Apple":{"type":"object","properties":{"seeds":{"oneOf":[{"type":"integer"},{"type":"string"}]}}}},"$schema":"http://json-schema.org/draft-04/schema#"}>
but: was <{"type":"object","properties":{"seeds":{"oneOf":[{"type":"integer","types":["integer"]},{"type":"string","types":["string"]}]}},"types":["object"],"definitions":{"Apple":{"type":"object","properties":{"seeds":{"oneOf":[{"type":"integer","types":["integer"]},{"type":"string","types":["string"]}]}},"types":["object"]}},"$schema":"http://json-schema.org/draft-04/schema#"}>
Raw output
java.lang.AssertionError: JSON schemas MUST match.
Expected: is <{"type":"object","properties":{"seeds":{"oneOf":[{"type":"integer"},{"type":"string"}]}},"definitions":{"Apple":{"type":"object","properties":{"seeds":{"oneOf":[{"type":"integer"},{"type":"string"}]}}}},"$schema":"http://json-schema.org/draft-04/schema#"}>
but: was <{"type":"object","properties":{"seeds":{"oneOf":[{"type":"integer","types":["integer"]},{"type":"string","types":["string"]}]}},"types":["object"],"definitions":{"Apple":{"type":"object","properties":{"seeds":{"oneOf":[{"type":"integer","types":["integer"]},{"type":"string","types":["string"]}]}},"types":["object"]}},"$schema":"http://json-schema.org/draft-04/schema#"}>
at org.hamcrest.MatcherAssert.assertThat(MatcherAssert.java:20)
at com.ebay.openapi.export.jsonschema.OpenApiToJsonSchemaTest.yamlWithOneOfOnProperty(OpenApiToJsonSchemaTest.java:78)
github-actions / Test Report
OpenApiToJsonSchemaTest.yamlWithRefs
JSON schemas MUST match.
Expected: is <{"type":"object","properties":{"apple":{"$ref":"#/definitions/Apple"}},"definitions":{"Response":{"type":"object","properties":{"apple":{"$ref":"#/definitions/Apple"}}},"Apple":{"type":"string"}},"$schema":"http://json-schema.org/draft-04/schema#"}>
but: was <{"type":"object","properties":{"apple":{"$ref":"#/definitions/Apple"}},"types":["object"],"definitions":{"Response":{"type":"object","properties":{"apple":{"$ref":"#/definitions/Apple"}},"types":["object"]},"Apple":{"type":"string","types":["string"]}},"$schema":"http://json-schema.org/draft-04/schema#"}>
Raw output
java.lang.AssertionError: JSON schemas MUST match.
Expected: is <{"type":"object","properties":{"apple":{"$ref":"#/definitions/Apple"}},"definitions":{"Response":{"type":"object","properties":{"apple":{"$ref":"#/definitions/Apple"}}},"Apple":{"type":"string"}},"$schema":"http://json-schema.org/draft-04/schema#"}>
but: was <{"type":"object","properties":{"apple":{"$ref":"#/definitions/Apple"}},"types":["object"],"definitions":{"Response":{"type":"object","properties":{"apple":{"$ref":"#/definitions/Apple"}},"types":["object"]},"Apple":{"type":"string","types":["string"]}},"$schema":"http://json-schema.org/draft-04/schema#"}>
at org.hamcrest.MatcherAssert.assertThat(MatcherAssert.java:20)
at com.ebay.openapi.export.jsonschema.OpenApiToJsonSchemaTest.yamlWithRefs(OpenApiToJsonSchemaTest.java:38)
github-actions / Test Report
OpenApiToJsonSchemaTest.yamlWithRequiredProperties
JSON schemas MUST match.
Expected: is <{"required":["name"],"type":"object","properties":{"name":{"type":"string"},"color":{"type":"string"}},"definitions":{"Apple":{"required":["name"],"type":"object","properties":{"name":{"type":"string"},"color":{"type":"string"}}}},"$schema":"http://json-schema.org/draft-04/schema#"}>
but: was <{"required":["name"],"type":"object","properties":{"name":{"type":"string","types":["string"]},"color":{"type":"string","types":["string"]}},"types":["object"],"definitions":{"Apple":{"required":["name"],"type":"object","properties":{"name":{"type":"string","types":["string"]},"color":{"type":"string","types":["string"]}},"types":["object"]}},"$schema":"http://json-schema.org/draft-04/schema#"}>
Raw output
java.lang.AssertionError: JSON schemas MUST match.
Expected: is <{"required":["name"],"type":"object","properties":{"name":{"type":"string"},"color":{"type":"string"}},"definitions":{"Apple":{"required":["name"],"type":"object","properties":{"name":{"type":"string"},"color":{"type":"string"}}}},"$schema":"http://json-schema.org/draft-04/schema#"}>
but: was <{"required":["name"],"type":"object","properties":{"name":{"type":"string","types":["string"]},"color":{"type":"string","types":["string"]}},"types":["object"],"definitions":{"Apple":{"required":["name"],"type":"object","properties":{"name":{"type":"string","types":["string"]},"color":{"type":"string","types":["string"]}},"types":["object"]}},"$schema":"http://json-schema.org/draft-04/schema#"}>
at org.hamcrest.MatcherAssert.assertThat(MatcherAssert.java:20)
at com.ebay.openapi.export.jsonschema.OpenApiToJsonSchemaTest.yamlWithRequiredProperties(OpenApiToJsonSchemaTest.java:169)
github-actions / Test Report
OpenApiToJsonSchemaTest.yamlWithSchemaPlusRefInPath
JSON schemas MUST match.
Expected: is <{"type":"object","properties":{"a":{"type":"string"},"b":{"type":"integer"},"c":{"type":"array","items":{"type":"boolean"}},"d":{"$ref":"#/definitions/refType"}},"definitions":{"refType":{"type":"string"}},"$schema":"http://json-schema.org/draft-04/schema#"}>
but: was <{"type":"object","properties":{"a":{"type":"string","types":["string"]},"b":{"type":"integer","types":["integer"]},"c":{"type":"array","items":{"type":"boolean","types":["boolean"]},"types":["array"]},"d":{"$ref":"#/definitions/refType"}},"types":["object"],"definitions":{"refType":{"type":"string","types":["string"]}},"$schema":"http://json-schema.org/draft-04/schema#"}>
Raw output
java.lang.AssertionError: JSON schemas MUST match.
Expected: is <{"type":"object","properties":{"a":{"type":"string"},"b":{"type":"integer"},"c":{"type":"array","items":{"type":"boolean"}},"d":{"$ref":"#/definitions/refType"}},"definitions":{"refType":{"type":"string"}},"$schema":"http://json-schema.org/draft-04/schema#"}>
but: was <{"type":"object","properties":{"a":{"type":"string","types":["string"]},"b":{"type":"integer","types":["integer"]},"c":{"type":"array","items":{"type":"boolean","types":["boolean"]},"types":["array"]},"d":{"$ref":"#/definitions/refType"}},"types":["object"],"definitions":{"refType":{"type":"string","types":["string"]}},"$schema":"http://json-schema.org/draft-04/schema#"}>
at org.hamcrest.MatcherAssert.assertThat(MatcherAssert.java:20)
at com.ebay.openapi.export.jsonschema.OpenApiToJsonSchemaTest.yamlWithSchemaPlusRefInPath(OpenApiToJsonSchemaTest.java:30)