github.com/rzurga/go-swagger@v0.28.1-0.20211109195225-5d1f453ffa3a/fixtures/bugs/842/fixture-842.yaml (about) 1 swagger: '2.0' 2 info: 3 title: polymorphic type containing an array of the base type 4 description: codegen fails to produce code that builds 5 paths: 6 /execute: 7 post: 8 responses: 9 200: 10 schema: 11 type: "array" 12 items: 13 $ref: "#/definitions/Value" 14 15 definitions: 16 Value: 17 type: "object" 18 discriminator: "ValueType" 19 required: 20 - "ValueType" 21 properties: 22 ValueType: 23 type: "string" 24 25 ValueArray: 26 allOf: 27 - $ref: "#/definitions/Value" 28 - required: 29 - "Values" 30 properties: 31 Values: 32 type: "array" 33 items: 34 $ref: "#/definitions/Value"