Skip to content

Commit 655da03

Browse files
committed
Update tests and create new one for nullables
1 parent 18a658d commit 655da03

File tree

22 files changed

+1424
-10
lines changed

22 files changed

+1424
-10
lines changed

testdata/jennies/rawtypes/constant_references/JSONSchema/constant_references.jsonschema.json

Lines changed: 11 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -53,12 +53,19 @@
5353
"default": "ValueA"
5454
},
5555
"other": {
56-
"allOf": [
56+
"anyOf": [
5757
{
58-
"$ref": "#/definitions/Enum"
58+
"allOf": [
59+
{
60+
"$ref": "#/definitions/Enum"
61+
}
62+
],
63+
"default": "ValueA"
64+
},
65+
{
66+
"type": "null"
5967
}
60-
],
61-
"default": "ValueA"
68+
]
6269
}
6370
}
6471
},

testdata/jennies/rawtypes/constant_references/OpenAPI/constant_references.openapi.json

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -61,12 +61,17 @@
6161
"default": "ValueA"
6262
},
6363
"other": {
64+
"nullable": true,
6465
"allOf": [
6566
{
66-
"$ref": "#/components/schemas/Enum"
67+
"allOf": [
68+
{
69+
"$ref": "#/components/schemas/Enum"
70+
}
71+
],
72+
"default": "ValueA"
6773
}
68-
],
69-
"default": "ValueA"
74+
]
7075
}
7176
}
7277
},

testdata/jennies/rawtypes/disjunctions/JSONSchema/disjunctions.jsonschema.json

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,14 @@
1313
"description": "Refresh rate or disabled."
1414
},
1515
"StringOrNull": {
16-
"type": "string"
16+
"anyOf": [
17+
{
18+
"type": "string"
19+
},
20+
{
21+
"type": "null"
22+
}
23+
]
1724
},
1825
"SomeStruct": {
1926
"type": "object",

testdata/jennies/rawtypes/disjunctions/OpenAPI/disjunctions.openapi.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,8 @@
2121
"description": "Refresh rate or disabled."
2222
},
2323
"StringOrNull": {
24-
"type": "string"
24+
"type": "string",
25+
"nullable": true
2526
},
2627
"SomeStruct": {
2728
"type": "object",

0 commit comments

Comments
 (0)