@@ -56,14 +56,16 @@ def app
5656 { 'text' => { 'type' => 'string' , 'description' => 'Content of something.' } ,
5757 'colors' => { 'type' => 'array' , 'items' => { 'type' => 'string' } , 'description' => 'Colors' } ,
5858 'created_at' => { 'type' => 'string' , 'format' => 'date-time' , 'description' => 'Created at the time.' } ,
59- 'kind' => { '$ref' => '#/definitions/ThisApi_Entities_Kind' ,
59+ 'kind' => { 'allOf' => [ { ' $ref' => '#/definitions/ThisApi_Entities_Kind' } ] ,
6060 'description' => 'The kind of this something.' } ,
61- 'kind2' => { '$ref' => '#/definitions/ThisApi_Entities_Kind' , 'description' => 'Secondary kind.' } ,
62- 'kind3' => { '$ref' => '#/definitions/ThisApi_Entities_Kind' , 'description' => 'Tertiary kind.' } ,
61+ 'kind2' => { 'allOf' => [ { '$ref' => '#/definitions/ThisApi_Entities_Kind' } ] ,
62+ 'description' => 'Secondary kind.' } ,
63+ 'kind3' => { 'allOf' => [ { '$ref' => '#/definitions/ThisApi_Entities_Kind' } ] ,
64+ 'description' => 'Tertiary kind.' } ,
6365 'tags' => { 'type' => 'array' , 'items' => { '$ref' => '#/definitions/ThisApi_Entities_Tag' } ,
6466 'description' => 'Tags.' } ,
65- 'relation' => { '$ref' => '#/definitions/ThisApi_Entities_Relation' , 'description' => 'A related model.' ,
66- 'x-other' => 'stuff' } ,
67+ 'relation' => { 'allOf' => [ { ' $ref' => '#/definitions/ThisApi_Entities_Relation' } ] ,
68+ 'description' => 'A related model.' , ' x-other' => 'stuff' } ,
6769 'code' => { 'type' => 'string' , 'description' => 'Error code' } ,
6870 'message' => { 'type' => 'string' , 'description' => 'Error message' } ,
6971 'attr' => { 'type' => 'string' , 'description' => 'Attribute' } } ,
@@ -409,8 +411,10 @@ def app
409411 expect ( subject [ 'TheseApi_Entities_Polymorphic' ] ) . to eql (
410412 'type' => 'object' ,
411413 'properties' => {
412- 'kind' => { '$ref' => '#/definitions/TheseApi_Entities_Kind' , 'description' => 'Polymorphic Kind' } ,
413- 'values' => { '$ref' => '#/definitions/TheseApi_Entities_Values' , 'description' => 'Polymorphic Values' } ,
414+ 'kind' => { 'allOf' => [ { '$ref' => '#/definitions/TheseApi_Entities_Kind' } ] ,
415+ 'description' => 'Polymorphic Kind' } ,
416+ 'values' => { 'allOf' => [ { '$ref' => '#/definitions/TheseApi_Entities_Values' } ] ,
417+ 'description' => 'Polymorphic Values' } ,
414418 'str' => { 'type' => 'string' , 'description' => 'Polymorphic String' } ,
415419 'num' => { 'type' => 'integer' , 'format' => 'int32' , 'description' => 'Polymorphic Number' }
416420 }
@@ -432,22 +436,28 @@ def app
432436 'type' => 'object' ,
433437 'properties' => {
434438 'text' => { 'type' => 'string' , 'description' => 'Content of something.' } ,
435- 'kind' => { '$ref' => '#/definitions/TheseApi_Entities_Kind' , 'description' => 'The kind of this something.' } ,
436- 'kind2' => { '$ref' => '#/definitions/TheseApi_Entities_Kind' , 'description' => 'Secondary kind.' } ,
437- 'kind3' => { '$ref' => '#/definitions/TheseApi_Entities_Kind' , 'description' => 'Tertiary kind.' } ,
439+ 'kind' => { 'allOf' => [ { '$ref' => '#/definitions/TheseApi_Entities_Kind' } ] ,
440+ 'description' => 'The kind of this something.' } ,
441+ 'kind2' => { 'allOf' => [ { '$ref' => '#/definitions/TheseApi_Entities_Kind' } ] ,
442+ 'description' => 'Secondary kind.' } ,
443+ 'kind3' => { 'allOf' => [ { '$ref' => '#/definitions/TheseApi_Entities_Kind' } ] ,
444+ 'description' => 'Tertiary kind.' } ,
438445 'tags' => { 'type' => 'array' , 'items' => { '$ref' => '#/definitions/TheseApi_Entities_Tag' } ,
439446 'description' => 'Tags.' } ,
440- 'relation' => { '$ref' => '#/definitions/TheseApi_Entities_Relation' , 'description' => 'A related model.' } ,
441- 'values' => { '$ref' => '#/definitions/TheseApi_Entities_Values' , 'description' => 'Tertiary kind.' } ,
442- 'nested' => { '$ref' => '#/definitions/TheseApi_Entities_Nested' , 'description' => 'Nested object.' } ,
443- 'nested_child' => { '$ref' => '#/definitions/TheseApi_Entities_NestedChild' ,
447+ 'relation' => { 'allOf' => [ { '$ref' => '#/definitions/TheseApi_Entities_Relation' } ] ,
448+ 'description' => 'A related model.' } ,
449+ 'values' => { 'allOf' => [ { '$ref' => '#/definitions/TheseApi_Entities_Values' } ] ,
450+ 'description' => 'Tertiary kind.' } ,
451+ 'nested' => { 'allOf' => [ { '$ref' => '#/definitions/TheseApi_Entities_Nested' } ] ,
452+ 'description' => 'Nested object.' } ,
453+ 'nested_child' => { 'allOf' => [ { '$ref' => '#/definitions/TheseApi_Entities_NestedChild' } ] ,
444454 'description' => 'Nested child object.' } ,
445455 'code' => { 'type' => 'string' , 'description' => 'Error code' } ,
446456 'message' => { 'type' => 'string' , 'description' => 'Error message' } ,
447- 'polymorphic' => { '$ref' => '#/definitions/TheseApi_Entities_Polymorphic' ,
457+ 'polymorphic' => { 'allOf' => [ { ' $ref' => '#/definitions/TheseApi_Entities_Polymorphic' } ] ,
448458 'description' => 'A polymorphic model.' } ,
449459 'mixed' => {
450- '$ref' => '#/definitions/TheseApi_Entities_MixedType' ,
460+ 'allOf' => [ { ' $ref' => '#/definitions/TheseApi_Entities_MixedType' } ] ,
451461 'description' => 'A model with mix of types.'
452462 } ,
453463 'attr' => { 'type' => 'string' , 'description' => 'Attribute' }
0 commit comments