Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

update deps (Jackson to 2.18.2, fix quotes in tests) #4828

Merged
merged 1 commit into from
Jan 16, 2025
Merged
Show file tree
Hide file tree
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
Original file line number Diff line number Diff line change
Expand Up @@ -94,11 +94,11 @@ public void testEnumRefProperty() {
" type: object\n" +
" properties:\n" +
" a:\n" +
" $ref: '#/components/schemas/TestEnum'\n" +
" $ref: \"#/components/schemas/TestEnum\"\n" +
" b:\n" +
" $ref: '#/components/schemas/TestEnum'\n" +
" $ref: \"#/components/schemas/TestEnum\"\n" +
" c:\n" +
" $ref: '#/components/schemas/TestSecondEnum'\n" +
" $ref: \"#/components/schemas/TestSecondEnum\"\n" +
" d:\n" +
" type: string\n" +
" enum:\n" +
Expand Down Expand Up @@ -133,11 +133,11 @@ public void testEnumRefPropertyWithFQNTypeNameResolver() {
" type: object\n" +
" properties:\n" +
" a:\n" +
" $ref: '#/components/schemas/io.swagger.v3.core.oas.models.TestEnum'\n" +
" $ref: \"#/components/schemas/io.swagger.v3.core.oas.models.TestEnum\"\n" +
" b:\n" +
" $ref: '#/components/schemas/io.swagger.v3.core.oas.models.TestEnum'\n" +
" $ref: \"#/components/schemas/io.swagger.v3.core.oas.models.TestEnum\"\n" +
" c:\n" +
" $ref: '#/components/schemas/io.swagger.v3.core.oas.models.TestSecondEnum'\n" +
" $ref: \"#/components/schemas/io.swagger.v3.core.oas.models.TestSecondEnum\"\n" +
" d:\n" +
" type: string\n" +
" enum:\n" +
Expand Down Expand Up @@ -173,7 +173,7 @@ public void testEnumRefPropertyGlobal() {
" type: object\n" +
" properties:\n" +
" enumValue:\n" +
" $ref: '#/components/schemas/TestEnum'\n" +
" $ref: \"#/components/schemas/TestEnum\"\n" +
"TestEnum:\n" +
" type: string\n" +
" enum:\n" +
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -428,7 +428,7 @@ public void testModelPropertyExampleJson() {
" type: object\n" +
" properties:\n" +
" exampleJson:\n" +
" $ref: '#/components/schemas/ExampleJson'\n" +
" $ref: \"#/components/schemas/ExampleJson\"\n" +
" example:\n" +
" id: 19877734";
SerializationMatchers.assertEqualsToYaml(readAll(modelWithPropertyExampleOverrideJson.class), yaml);
Expand Down Expand Up @@ -464,7 +464,7 @@ public void testModelPropertyImplExampleJson() {
" type: object\n" +
" properties:\n" +
" exampleJson:\n" +
" $ref: '#/components/schemas/ExampleJson'\n";
" $ref: \"#/components/schemas/ExampleJson\"\n";
SerializationMatchers.assertEqualsToYaml(readAll(modelWithPropertyImplExampleOverrideJson.class), yaml);
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -291,10 +291,10 @@ public void testDeserializeRefCallback() throws Exception {
" description: voila!\n" +
" callbacks:\n" +
" testCallback1:\n" +
" $ref: '#/components/callbacks/Callback'\n" +
" $ref: \"#/components/callbacks/Callback\"\n" +
" callbacks:\n" +
" testCallback1:\n" +
" $ref: '#/components/callbacks/Callback'\n" +
" $ref: \"#/components/callbacks/Callback\"\n" +
"components:\n" +
" callbacks:\n" +
" Callback:\n" +
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,19 +29,19 @@ public void testAllofResolving() {
" - type: object\n" +
" description: First user schema property\n" +
" nullable: true\n" +
" - $ref: '#/components/schemas/UserProperty'\n" +
" - $ref: \"#/components/schemas/UserProperty\"\n" +
" propertyTwo:\n" +
" allOf:\n" +
" - type: object\n" +
" description: Second user schema property\n" +
" example: example value for propertyTwo\n" +
" - $ref: '#/components/schemas/UserProperty'\n" +
" - $ref: \"#/components/schemas/UserProperty\"\n" +
" propertyThree:\n" +
" allOf:\n" +
" - type: object\n" +
" description: \"Third user schema property, with example for testing\"\n" +
" example: example value for propertyThree\n" +
" - $ref: '#/components/schemas/UserProperty'\n";
" - $ref: \"#/components/schemas/UserProperty\"\n";

SerializationMatchers.assertEqualsToYaml(c.getDefinedModels(), expectedYaml);
// stringSchemaMap = c.readAll(InlineSchemaSecond.class);
Expand All @@ -53,7 +53,7 @@ public void testAllofResolving() {
" type: object\n" +
" properties:\n" +
" basicProperty:\n" +
" $ref: '#/components/schemas/BasicProperty'\n" +
" $ref: \"#/components/schemas/BasicProperty\"\n" +
" description: Represents an order-specific property\n" +
" example: Order-specific example value\n" +
"OrderSchema:\n" +
Expand All @@ -64,13 +64,13 @@ public void testAllofResolving() {
" - type: object\n" +
" description: First order schema property\n" +
" nullable: true\n" +
" - $ref: '#/components/schemas/OrderProperty'\n" +
" - $ref: \"#/components/schemas/OrderProperty\"\n" +
" userProperty:\n" +
" allOf:\n" +
" - type: object\n" +
" description: \"Order schema property, references UserProperty\"\n" +
" example: example value for userProperty\n" +
" - $ref: '#/components/schemas/UserProperty'\n" +
" - $ref: \"#/components/schemas/UserProperty\"\n" +
"UserProperty:\n" +
" type: object\n" +
" description: Represents a user-specific property\n" +
Expand All @@ -83,19 +83,19 @@ public void testAllofResolving() {
" - type: object\n" +
" description: First user schema property\n" +
" nullable: true\n" +
" - $ref: '#/components/schemas/UserProperty'\n" +
" - $ref: \"#/components/schemas/UserProperty\"\n" +
" propertyTwo:\n" +
" allOf:\n" +
" - type: object\n" +
" description: Second user schema property\n" +
" example: example value for propertyTwo\n" +
" - $ref: '#/components/schemas/UserProperty'\n" +
" - $ref: \"#/components/schemas/UserProperty\"\n" +
" propertyThree:\n" +
" allOf:\n" +
" - type: object\n" +
" description: \"Third user schema property, with example for testing\"\n" +
" example: example value for propertyThree\n" +
" - $ref: '#/components/schemas/UserProperty'\n";
" - $ref: \"#/components/schemas/UserProperty\"\n";
SerializationMatchers.assertEqualsToYaml(c.getDefinedModels(), expectedYaml);
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -109,7 +109,7 @@ public void testTicket2169() {
" type: string\n" +
" readOnly: true\n" +
" data:\n" +
" $ref: '#/components/schemas/Data'\n" +
" $ref: \"#/components/schemas/Data\"\n" +
" GetterJsonPropertyOnField:\n" +
" type: string\n" +
" GetterJsonPropertyOnFieldReadWrite:\n" +
Expand Down Expand Up @@ -141,7 +141,7 @@ public void testTicket2845() {
" type: object\n" +
" properties:\n" +
" child:\n" +
" $ref: '#/components/schemas/Ticket2845Child'");
" $ref: \"#/components/schemas/Ticket2845Child\"");

/*
TODO: Test demonstrating annotation not being resolved when class is used/refernces elsewhere with different annotations
Expand All @@ -165,9 +165,9 @@ and referenced (in the same or different class) with no or different @JsonIgnor
" type: object\n" +
" properties:\n" +
" child:\n" +
" $ref: '#/components/schemas/Ticket2845Child'\n" +
" $ref: \"#/components/schemas/Ticket2845Child\"\n" +
" childNoAnnotation:\n" +
" $ref: '#/components/schemas/Ticket2845Child'");
" $ref: \"#/components/schemas/Ticket2845Child\"");
}

static class Ticket2845Parent {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ public void testTicket2189() {
"SubClass:\n" +
" type: object\n" +
" allOf:\n" +
" - $ref: '#/components/schemas/BaseClass'\n" +
" - $ref: \"#/components/schemas/BaseClass\"\n" +
" - type: object\n" +
" properties:\n" +
" subClassProperty:\n" +
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ public void testCyclicBean() throws Exception {
" type: array\n" +
" description: Other related things\n" +
" items:\n" +
" $ref: '#/components/schemas/MyThing'\n" +
" $ref: \"#/components/schemas/MyThing\"\n" +
"description: Thing");
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ public void testSubType() throws Exception {
"Ticket2862ModelImpl:\n" +
" type: string\n" +
" allOf:\n" +
" - $ref: '#/components/schemas/Ticket2862Model'\n" +
" - $ref: \"#/components/schemas/Ticket2862Model\"\n" +
" enum:\n" +
" - VALUE1\n" +
" - VALUE2\n");
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ public void test2884_null() {
Assert.assertNotNull(o);
Assert.assertTrue(o.get$ref().contains(Ticket2884ModelClass.class.getSimpleName()));
SerializationMatchers.assertEqualsToYaml(schema.schema.getProperties(), "Ticket2884ModelClass:\n" +
" $ref: '#/components/schemas/Ticket2884ModelClass'");
" $ref: \"#/components/schemas/Ticket2884ModelClass\"");

}
}
Original file line number Diff line number Diff line change
Expand Up @@ -37,9 +37,9 @@ public void testPropertyName() throws Exception {
" name:\n" +
" type: string\n" +
" perServing:\n" +
" $ref: '#/components/schemas/QuantitativeValue'\n" +
" $ref: \"#/components/schemas/QuantitativeValue\"\n" +
" per100Gram:\n" +
" $ref: '#/components/schemas/QuantitativeValue'\n" +
" $ref: \"#/components/schemas/QuantitativeValue\"\n" +
" description: Nutritional value specification");
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -42,11 +42,11 @@ public void testLocalTime() throws Exception {
" name:\n" +
" type: string\n" +
" a:\n" +
" $ref: '#/components/schemas/LocalTime'\n" +
" $ref: \"#/components/schemas/LocalTime\"\n" +
" b:\n" +
" $ref: '#/components/schemas/LocalTime'\n" +
" $ref: \"#/components/schemas/LocalTime\"\n" +
" c:\n" +
" $ref: '#/components/schemas/LocalTime'\n" +
" $ref: \"#/components/schemas/LocalTime\"\n" +
" d:\n" +
" type: string\n" +
" format: date-time\n" +
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ public void testTicket3030() throws Exception {
String yaml = "Child:\n" +
" type: object\n" +
" allOf:\n" +
" - $ref: '#/components/schemas/Parent'\n" +
" - $ref: \"#/components/schemas/Parent\"\n" +
" - type: object\n" +
" properties:\n" +
" property:\n" +
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ public void testTicket3063() throws Exception {
" type: object\n" +
" description: SubClass\n" +
" allOf:\n" +
" - $ref: '#/components/schemas/BaseClass'\n" +
" - $ref: \"#/components/schemas/BaseClass\"\n" +
" - type: object\n" +
" properties:\n" +
" additionalPropertyWhichShouldBeThere:\n" +
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -50,18 +50,18 @@ public void testTicket3197() throws Exception {
" discriminator:\n" +
" propertyName: type\n" +
" mapping:\n" +
" RaceCar: '#/components/schemas/RaceCar'\n" +
" SportCar: '#/components/schemas/SportCar'\n" +
" RaceCar: \"#/components/schemas/RaceCar\"\n" +
" SportCar: \"#/components/schemas/SportCar\"\n" +
" oneOf:\n" +
" - $ref: '#/components/schemas/RaceCar'\n" +
" - $ref: '#/components/schemas/SportCar'\n" +
" - $ref: \"#/components/schemas/RaceCar\"\n" +
" - $ref: \"#/components/schemas/SportCar\"\n" +
"RaceCar:\n" +
" required:\n" +
" - carMetaData\n" +
" - id\n" +
" type: object\n" +
" allOf:\n" +
" - $ref: '#/components/schemas/Car'\n" +
" - $ref: \"#/components/schemas/Car\"\n" +
" - type: object\n" +
" properties:\n" +
" id:\n" +
Expand All @@ -74,7 +74,7 @@ public void testTicket3197() throws Exception {
" - id\n" +
" type: object\n" +
" allOf:\n" +
" - $ref: '#/components/schemas/Car'\n" +
" - $ref: \"#/components/schemas/Car\"\n" +
" - type: object\n" +
" properties:\n" +
" id:\n" +
Expand Down Expand Up @@ -108,11 +108,11 @@ public void testTicket3197AsSibling() throws Exception {
" discriminator:\n" +
" propertyName: type\n" +
" mapping:\n" +
" RaceCar: '#/components/schemas/RaceCar'\n" +
" SportCar: '#/components/schemas/SportCar'\n" +
" RaceCar: \"#/components/schemas/RaceCar\"\n" +
" SportCar: \"#/components/schemas/SportCar\"\n" +
" oneOf:\n" +
" - $ref: '#/components/schemas/RaceCar'\n" +
" - $ref: '#/components/schemas/SportCar'\n" +
" - $ref: \"#/components/schemas/RaceCar\"\n" +
" - $ref: \"#/components/schemas/SportCar\"\n" +
"RaceCar:\n" +
" required:\n" +
" - carMetaData\n" +
Expand All @@ -125,7 +125,7 @@ public void testTicket3197AsSibling() throws Exception {
" model:\n" +
" type: string\n" +
" allOf:\n" +
" - $ref: '#/components/schemas/Car'\n" +
" - $ref: \"#/components/schemas/Car\"\n" +
"SportCar:\n" +
" required:\n" +
" - id\n" +
Expand All @@ -137,7 +137,7 @@ public void testTicket3197AsSibling() throws Exception {
" model:\n" +
" type: string\n" +
" allOf:\n" +
" - $ref: '#/components/schemas/Car'\n";
" - $ref: \"#/components/schemas/Car\"\n";

SerializationMatchers.assertEqualsToYaml(myContext.getDefinedModels(), yaml);
ModelResolver.composedModelPropertiesAsSibling = false;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,12 +29,12 @@ public void testSelfReferencingOptional() throws Exception {
" type: object\n" +
" properties:\n" +
" model:\n" +
" $ref: '#/components/schemas/Model'\n" +
" $ref: \"#/components/schemas/Model\"\n" +
"ModelContainer:\n" +
" type: object\n" +
" properties:\n" +
" model:\n" +
" $ref: '#/components/schemas/Model'\n");
" $ref: \"#/components/schemas/Model\"\n");

}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,12 +25,12 @@ public void testSelfReferencingOptional() throws Exception {
" type: object\n" +
" properties:\n" +
" model:\n" +
" $ref: '#/components/schemas/Model'\n" +
" $ref: \"#/components/schemas/Model\"\n" +
"ModelContainer:\n" +
" type: object\n" +
" properties:\n" +
" model:\n" +
" $ref: '#/components/schemas/Model'\n" +
" $ref: \"#/components/schemas/Model\"\n" +
" bytes:\n" +
" type: string\n" +
" format: byte");
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ public void testTicket3853() {
"io.swagger.v3.core.resolving.Ticket3853Test$SubClass:\n" +
" type: object\n" +
" allOf:\n" +
" - $ref: '#/components/schemas/io.swagger.v3.core.resolving.Ticket3853Test$BaseClass'\n" +
" - $ref: \"#/components/schemas/io.swagger.v3.core.resolving.Ticket3853Test$BaseClass\"\n" +
" - type: object\n" +
" properties:\n" +
" subClassProperty:\n" +
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ public void testJsonValueSchemaAnnotation() {
SerializationMatchers.assertEqualsToYaml(context.getDefinedModels(), "A1_Output:\n" +
" type: object\n" +
" allOf:\n" +
" - $ref: '#/components/schemas/A_Output'\n" +
" - $ref: \"#/components/schemas/A_Output\"\n" +
" - type: object\n" +
" properties:\n" +
" a1_out:\n" +
Expand Down
Loading
Loading