mirror of
https://github.com/OpenAPITools/openapi-generator.git
synced 2025-12-03 00:43:46 +00:00
fix: ExampleGenerator correctly generates allOf composed schemas (#17499)
* fix: ExampleGenerator correctly generates allOf composed schemas Changes the previous behavior of generating `null` examples for allOf composed schemas. Fixes #17497 * fix: ExampleGenerator correctly generates anyOf and oneOf composed schemas Changes the previous behavior of generating `null` examples for anyOf and oneOf composed schemas. To generate a oneOf/anyOf example, we generate the example using the first valid schema available. In case of a $ref, we use the first valid reference. Fixes #17497
This commit is contained in:
@@ -1942,6 +1942,10 @@ components:
|
||||
otherProperty:
|
||||
type: string
|
||||
type: object
|
||||
example:
|
||||
otherProperty: otherProperty
|
||||
nullableProperty: nullableProperty
|
||||
type: ChildWithNullable
|
||||
StringBooleanMap:
|
||||
additionalProperties:
|
||||
type: boolean
|
||||
|
||||
Reference in New Issue
Block a user