From 09a4e353c58bad50f7db5ed3aea53c38c6857434 Mon Sep 17 00:00:00 2001 From: Steven Serrata Date: Fri, 2 Aug 2024 11:13:57 -0500 Subject: [PATCH 1/8] process properties before allOf to ensure rendering --- .../src/markdown/createSchema.ts | 117 ++++++++++-------- 1 file changed, 63 insertions(+), 54 deletions(-) diff --git a/packages/docusaurus-plugin-openapi-docs/src/markdown/createSchema.ts b/packages/docusaurus-plugin-openapi-docs/src/markdown/createSchema.ts index 79feea1d0..7cbae49da 100644 --- a/packages/docusaurus-plugin-openapi-docs/src/markdown/createSchema.ts +++ b/packages/docusaurus-plugin-openapi-docs/src/markdown/createSchema.ts @@ -615,6 +615,7 @@ function createEdges({ } const schemaName = getSchemaName(schema); + if (discriminator !== undefined && discriminator.propertyName === name) { return createPropertyDiscriminator( name, @@ -635,6 +636,47 @@ function createEdges({ ); } + if (schema.properties !== undefined) { + return createDetailsNode( + name, + schemaName, + schema, + required, + schema.nullable + ); + } + + if (schema.additionalProperties !== undefined) { + return createDetailsNode( + name, + schemaName, + schema, + required, + schema.nullable + ); + } + + // array of objects + if (schema.items?.properties !== undefined) { + return createDetailsNode( + name, + schemaName, + schema, + required, + schema.nullable + ); + } + + if (schema.items?.anyOf !== undefined || schema.items?.oneOf !== undefined) { + return createDetailsNode( + name, + schemaName, + schema, + required, + schema.nullable + ); + } + if (schema.allOf !== undefined) { const { mergedSchemas }: { mergedSchemas: SchemaObject } = mergeAllOf( schema.allOf @@ -707,47 +749,6 @@ function createEdges({ }); } - if (schema.properties !== undefined) { - return createDetailsNode( - name, - schemaName, - schema, - required, - schema.nullable - ); - } - - if (schema.additionalProperties !== undefined) { - return createDetailsNode( - name, - schemaName, - schema, - required, - schema.nullable - ); - } - - // array of objects - if (schema.items?.properties !== undefined) { - return createDetailsNode( - name, - schemaName, - schema, - required, - schema.nullable - ); - } - - if (schema.items?.anyOf !== undefined || schema.items?.oneOf !== undefined) { - return createDetailsNode( - name, - schemaName, - schema, - required, - schema.nullable - ); - } - // primitives and array of non-objects return create("SchemaItem", { collapsible: false, @@ -785,6 +786,24 @@ export function createNodes( if (schema.oneOf !== undefined || schema.anyOf !== undefined) { nodes.push(createAnyOneOf(schema)); + delete schema.oneOf; + delete schema.anyOf; + } + + if (schema.properties !== undefined) { + nodes.push(createProperties(schema)); + delete schema.properties; + } + + if (schema.additionalProperties !== undefined) { + nodes.push(createAdditionalProperties(schema)); + delete schema.additionalProperties; + } + + // TODO: figure out how to handle array of objects + if (schema.items !== undefined) { + nodes.push(createItems(schema)); + delete schema.items; } if (schema.allOf !== undefined) { @@ -795,26 +814,16 @@ export function createNodes( mergedSchemas.anyOf !== undefined ) { nodes.push(createAnyOneOf(mergedSchemas)); + delete mergedSchemas.oneOf; + delete mergedSchemas.anyOf; } if (mergedSchemas.properties !== undefined) { nodes.push(createProperties(mergedSchemas)); + delete mergedSchemas.properties; } } - if (schema.properties !== undefined) { - nodes.push(createProperties(schema)); - } - - if (schema.additionalProperties !== undefined) { - nodes.push(createAdditionalProperties(schema)); - } - - // TODO: figure out how to handle array of objects - if (schema.items !== undefined) { - nodes.push(createItems(schema)); - } - if (nodes.length && nodes.length > 0) { return nodes.filter(Boolean).flat(); } From 92c4345a4471f9472e6f81550022ca7835457b6b Mon Sep 17 00:00:00 2001 From: Steven Serrata Date: Fri, 2 Aug 2024 11:14:08 -0500 Subject: [PATCH 2/8] update tests --- .../__snapshots__/createSchema.test.ts.snap | 43 ++++++- .../src/markdown/createSchema.test.ts | 112 ++++++++++++------ 2 files changed, 117 insertions(+), 38 deletions(-) diff --git a/packages/docusaurus-plugin-openapi-docs/src/markdown/__snapshots__/createSchema.test.ts.snap b/packages/docusaurus-plugin-openapi-docs/src/markdown/__snapshots__/createSchema.test.ts.snap index 566438c29..89a8a4a25 100644 --- a/packages/docusaurus-plugin-openapi-docs/src/markdown/__snapshots__/createSchema.test.ts.snap +++ b/packages/docusaurus-plugin-openapi-docs/src/markdown/__snapshots__/createSchema.test.ts.snap @@ -223,7 +223,48 @@ Array [ ] `; -exports[`createNodes should create readable MODs for oneOf primitive properties 1`] = ` +exports[`createNodes allOf should render same-level properties with allOf 1`] = ` +Array [ + "; +", + "; +", + "; +", + "; +", +] +`; + +exports[`createNodes oneOf should create readable MODs for oneOf primitive properties 1`] = ` Array [ "
diff --git a/packages/docusaurus-plugin-openapi-docs/src/markdown/createSchema.test.ts b/packages/docusaurus-plugin-openapi-docs/src/markdown/createSchema.test.ts index 978fcbf4e..cb89c0629 100644 --- a/packages/docusaurus-plugin-openapi-docs/src/markdown/createSchema.test.ts +++ b/packages/docusaurus-plugin-openapi-docs/src/markdown/createSchema.test.ts @@ -11,50 +11,88 @@ import { createNodes } from "./createSchema"; import { SchemaObject } from "../openapi/types"; describe("createNodes", () => { - it("should create readable MODs for oneOf primitive properties", async () => { - const schema: SchemaObject = { - "x-tags": ["clown"], - type: "object", - properties: { - oneOfProperty: { - oneOf: [ - { - type: "object", - properties: { - noseLength: { - type: "number", + describe("oneOf", () => { + it("should create readable MODs for oneOf primitive properties", async () => { + const schema: SchemaObject = { + "x-tags": ["clown"], + type: "object", + properties: { + oneOfProperty: { + oneOf: [ + { + type: "object", + properties: { + noseLength: { + type: "number", + }, }, + required: ["noseLength"], + description: "Clown's nose length", }, - required: ["noseLength"], - description: "Clown's nose length", - }, - { - type: "array", - items: { + { + type: "array", + items: { + type: "string", + }, + description: "Array of strings", + }, + { + type: "boolean", + }, + { + type: "number", + }, + { + type: "string", + }, + ], + }, + }, + }; + expect( + await Promise.all( + createNodes(schema, "request").map( + async (md: any) => await prettier.format(md, { parser: "babel" }) + ) + ) + ).toMatchSnapshot(); + }); + }); + + describe("allOf", () => { + it("should render same-level properties with allOf", async () => { + const schema: SchemaObject = { + allOf: [ + { + type: "object", + properties: { + allOfProp1: { + type: "string", + }, + allOfProp2: { type: "string", }, - description: "Array of strings", - }, - { - type: "boolean", - }, - { - type: "number", - }, - { - type: "string", }, - ], + }, + ], + properties: { + parentProp1: { + type: "string", + }, + parentProp2: { + type: "string", + }, }, - }, - }; - expect( - await Promise.all( - createNodes(schema, "request").map( - async (md: any) => await prettier.format(md, { parser: "babel" }) + }; + + expect( + await Promise.all( + createNodes(schema, "response").map( + async (md: any) => await prettier.format(md, { parser: "babel" }) + ) ) - ) - ).toMatchSnapshot(); + ).toMatchSnapshot(); + }); }); describe("additionalProperties", () => { From ae993d1382c39b692603a7896a565be90eb993a6 Mon Sep 17 00:00:00 2001 From: Steven Serrata Date: Fri, 2 Aug 2024 11:20:54 -0500 Subject: [PATCH 3/8] remove delete schema lines added for testing --- .../src/markdown/createSchema.ts | 8 -------- 1 file changed, 8 deletions(-) diff --git a/packages/docusaurus-plugin-openapi-docs/src/markdown/createSchema.ts b/packages/docusaurus-plugin-openapi-docs/src/markdown/createSchema.ts index 7cbae49da..a0cc0775a 100644 --- a/packages/docusaurus-plugin-openapi-docs/src/markdown/createSchema.ts +++ b/packages/docusaurus-plugin-openapi-docs/src/markdown/createSchema.ts @@ -786,24 +786,19 @@ export function createNodes( if (schema.oneOf !== undefined || schema.anyOf !== undefined) { nodes.push(createAnyOneOf(schema)); - delete schema.oneOf; - delete schema.anyOf; } if (schema.properties !== undefined) { nodes.push(createProperties(schema)); - delete schema.properties; } if (schema.additionalProperties !== undefined) { nodes.push(createAdditionalProperties(schema)); - delete schema.additionalProperties; } // TODO: figure out how to handle array of objects if (schema.items !== undefined) { nodes.push(createItems(schema)); - delete schema.items; } if (schema.allOf !== undefined) { @@ -814,13 +809,10 @@ export function createNodes( mergedSchemas.anyOf !== undefined ) { nodes.push(createAnyOneOf(mergedSchemas)); - delete mergedSchemas.oneOf; - delete mergedSchemas.anyOf; } if (mergedSchemas.properties !== undefined) { nodes.push(createProperties(mergedSchemas)); - delete mergedSchemas.properties; } } From 9ed8c35256121d5911659332318ae21f292f39b4 Mon Sep 17 00:00:00 2001 From: Steven Serrata Date: Fri, 2 Aug 2024 12:04:01 -0500 Subject: [PATCH 4/8] add additional allOf test cases --- .../__snapshots__/createSchema.test.ts.snap | 104 +++++++++ .../src/markdown/createSchema.test.ts | 215 ++++++++++++++++++ 2 files changed, 319 insertions(+) diff --git a/packages/docusaurus-plugin-openapi-docs/src/markdown/__snapshots__/createSchema.test.ts.snap b/packages/docusaurus-plugin-openapi-docs/src/markdown/__snapshots__/createSchema.test.ts.snap index 89a8a4a25..82bff053d 100644 --- a/packages/docusaurus-plugin-openapi-docs/src/markdown/__snapshots__/createSchema.test.ts.snap +++ b/packages/docusaurus-plugin-openapi-docs/src/markdown/__snapshots__/createSchema.test.ts.snap @@ -223,6 +223,110 @@ Array [ ] `; +exports[`createNodes allOf should correctly deep merge properties in allOf schemas 1`] = ` +Array [ + " +
+ + + deepProp + object + + +
+ + +
+
+
; +", +] +`; + +exports[`createNodes allOf should correctly handle shared required properties across allOf schemas 1`] = ` +Array [ + "; +", + "; +", +] +`; + +exports[`createNodes allOf should correctly merge nested properties from multiple allOf schemas 1`] = ` +Array [ + " +
+ + + outerProp1 + object + + +
+ +
+
+
; +", + " +
+ + + outerProp2 + object + + +
+ +
+
+
; +", +] +`; + exports[`createNodes allOf should render same-level properties with allOf 1`] = ` Array [ " { ) ).toMatchSnapshot(); }); + + it("should correctly merge nested properties from multiple allOf schemas", async () => { + const schema: SchemaObject = { + allOf: [ + { + type: "object", + properties: { + outerProp1: { + type: "object", + properties: { + innerProp1: { + type: "string", + }, + }, + }, + }, + }, + { + type: "object", + properties: { + outerProp2: { + type: "object", + properties: { + innerProp2: { + type: "number", + }, + }, + }, + }, + }, + ], + }; + + expect( + await Promise.all( + createNodes(schema, "response").map( + async (md: any) => await prettier.format(md, { parser: "babel" }) + ) + ) + ).toMatchSnapshot(); + }); + + it("should correctly handle shared required properties across allOf schemas", async () => { + const schema: SchemaObject = { + allOf: [ + { + type: "object", + properties: { + sharedProp: { + type: "string", + }, + }, + required: ["sharedProp"], + }, + { + type: "object", + properties: { + anotherProp: { + type: "number", + }, + }, + required: ["anotherProp"], + }, + ], + }; + + expect( + await Promise.all( + createNodes(schema, "response").map( + async (md: any) => await prettier.format(md, { parser: "babel" }) + ) + ) + ).toMatchSnapshot(); + }); + + // Could not resolve values for path:"properties.conflictingProp.type". They are probably incompatible. Values: + // "string" + // "number" + // it("should handle conflicting properties in allOf schemas", async () => { + // const schema: SchemaObject = { + // allOf: [ + // { + // type: "object", + // properties: { + // conflictingProp: { + // type: "string", + // }, + // }, + // }, + // { + // type: "object", + // properties: { + // conflictingProp: { + // type: "number", + // }, + // }, + // }, + // ], + // }; + + // expect( + // await Promise.all( + // createNodes(schema, "response").map( + // async (md: any) => await prettier.format(md, { parser: "babel" }) + // ) + // ) + // ).toMatchSnapshot(); + // }); + + // Could not resolve values for path:"type". They are probably incompatible. Values: + // "object" + // "array" + // it("should handle mixed data types in allOf schemas", async () => { + // const schema: SchemaObject = { + // allOf: [ + // { + // type: "object", + // properties: { + // mixedTypeProp1: { + // type: "string", + // }, + // }, + // }, + // { + // type: "array", + // items: { + // type: "number", + // }, + // }, + // ], + // }; + + // expect( + // await Promise.all( + // createNodes(schema, "response").map( + // async (md: any) => await prettier.format(md, { parser: "babel" }) + // ) + // ) + // ).toMatchSnapshot(); + // }); + + it("should correctly deep merge properties in allOf schemas", async () => { + const schema: SchemaObject = { + allOf: [ + { + type: "object", + properties: { + deepProp: { + type: "object", + properties: { + innerProp1: { + type: "string", + }, + }, + }, + }, + }, + { + type: "object", + properties: { + deepProp: { + type: "object", + properties: { + innerProp2: { + type: "number", + }, + }, + }, + }, + }, + ], + }; + + expect( + await Promise.all( + createNodes(schema, "response").map( + async (md: any) => await prettier.format(md, { parser: "babel" }) + ) + ) + ).toMatchSnapshot(); + }); + + // it("should handle discriminator with allOf schemas", async () => { + // const schema: SchemaObject = { + // allOf: [ + // { + // type: "object", + // discriminator: { + // propertyName: "type", + // }, + // properties: { + // type: { + // type: "string", + // }, + // }, + // }, + // { + // type: "object", + // properties: { + // specificProp: { + // type: "string", + // }, + // }, + // }, + // ], + // }; + + // expect( + // await Promise.all( + // createNodes(schema, "response").map( + // async (md: any) => await prettier.format(md, { parser: "babel" }) + // ) + // ) + // ).toMatchSnapshot(); + // }); }); describe("additionalProperties", () => { From af3bf28c60eabc4d142142f91595c7e474e6be8f Mon Sep 17 00:00:00 2001 From: Steven Serrata Date: Fri, 2 Aug 2024 12:04:28 -0500 Subject: [PATCH 5/8] add tests to documentation --- demo/docusaurus.config.ts | 14 ++ demo/examples/tests/allOf.yaml | 279 +++++++++++++++++++++++++++++++++ demo/sidebars.ts | 14 ++ 3 files changed, 307 insertions(+) create mode 100644 demo/examples/tests/allOf.yaml diff --git a/demo/docusaurus.config.ts b/demo/docusaurus.config.ts index 0c051fc29..ed511aece 100644 --- a/demo/docusaurus.config.ts +++ b/demo/docusaurus.config.ts @@ -71,6 +71,10 @@ const config: Config = { label: "Petstore (versioned)", to: "/category/petstore-versioned-api", }, + { + label: "Tests", + to: "/category/tests", + }, ], }, { @@ -268,6 +272,16 @@ const config: Config = { }, showSchemas: true, } satisfies OpenApiPlugin.Options, + tests: { + specPath: "examples/tests", + outputDir: "docs/tests", + sidebarOptions: { + groupPathsBy: "tag", + categoryLinkSource: "info", + }, + hideSendButton: true, + showSchemas: true, + } satisfies OpenApiPlugin.Options, } satisfies Plugin.PluginOptions, }, ], diff --git a/demo/examples/tests/allOf.yaml b/demo/examples/tests/allOf.yaml new file mode 100644 index 000000000..2c2e7817e --- /dev/null +++ b/demo/examples/tests/allOf.yaml @@ -0,0 +1,279 @@ +openapi: 3.0.1 +info: + title: AllOf Variations API + description: Demonstrates various allOf schema combinations. + version: 1.0.0 +paths: + /multiple-allof-nested: + get: + tags: + - allOf + summary: Multiple allOf with Nested Properties + description: | + Schema: + ```yaml + allOf: + - type: object + properties: + outerProp1: + type: object + properties: + innerProp1: + type: string + - type: object + properties: + outerProp2: + type: object + properties: + innerProp2: + type: number + ``` + responses: + "200": + description: Successful response + content: + application/json: + schema: + allOf: + - type: object + properties: + outerProp1: + type: object + properties: + innerProp1: + type: string + - type: object + properties: + outerProp2: + type: object + properties: + innerProp2: + type: number + + /allof-shared-required: + get: + tags: + - allOf + summary: allOf with Shared Required Properties + description: | + Schema: + ```yaml + allOf: + - type: object + properties: + sharedProp: + type: string + required: [sharedProp] + - type: object + properties: + anotherProp: + type: number + required: [anotherProp] + ``` + responses: + "200": + description: Successful response + content: + application/json: + schema: + allOf: + - type: object + properties: + sharedProp: + type: string + required: [sharedProp] + - type: object + properties: + anotherProp: + type: number + required: [anotherProp] + + # /allof-conflicting-properties: + # get: + # tags: + # - allOf + # summary: allOf with Conflicting Properties + # description: | + # Schema: + # ```yaml + # allOf: + # - type: object + # properties: + # conflictingProp: + # type: string + # - type: object + # properties: + # conflictingProp: + # type: number + # ``` + # responses: + # '200': + # description: Successful response + # content: + # application/json: + # schema: + # allOf: + # - type: object + # properties: + # conflictingProp: + # type: string + # - type: object + # properties: + # conflictingProp: + # type: number + + # /allof-mixed-data-types: + # get: + # tags: + # - allOf + # summary: allOf with Mixed Data Types + # description: | + # Schema: + # ```yaml + # allOf: + # - type: object + # properties: + # mixedTypeProp1: + # type: string + # - type: array + # items: + # type: number + # ``` + # responses: + # '200': + # description: Successful response + # content: + # application/json: + # schema: + # allOf: + # - type: object + # properties: + # mixedTypeProp1: + # type: string + # - type: array + # items: + # type: number + + /allof-deep-merging: + get: + tags: + - allOf + summary: allOf with Deep Merging + description: | + Schema: + ```yaml + allOf: + - type: object + properties: + deepProp: + type: object + properties: + innerProp1: + type: string + - type: object + properties: + deepProp: + type: object + properties: + innerProp2: + type: number + ``` + responses: + "200": + description: Successful response + content: + application/json: + schema: + allOf: + - type: object + properties: + deepProp: + type: object + properties: + innerProp1: + type: string + - type: object + properties: + deepProp: + type: object + properties: + innerProp2: + type: number + + /allof-discriminator: + get: + tags: + - allOf + summary: allOf with Discriminator + description: | + Schema: + ```yaml + allOf: + - type: object + discriminator: + propertyName: type + properties: + type: + type: string + - type: object + properties: + specificProp: + type: string + ``` + responses: + "200": + description: Successful response + content: + application/json: + schema: + allOf: + - type: object + discriminator: + propertyName: type + properties: + type: + type: string + - type: object + properties: + specificProp: + type: string + + /allof-same-level-properties: + get: + tags: + - allOf + summary: allOf with Same-Level Properties + description: | + Schema: + ```yaml + allOf: + - type: object + properties: + allOfProp1: + type: string + allOfProp2: + type: string + properties: + parentProp1: + type: string + parentProp2: + type: string + ``` + responses: + "200": + description: Successful response + content: + application/json: + schema: + allOf: + - type: object + properties: + allOfProp1: + type: string + allOfProp2: + type: string + properties: + parentProp1: + type: string + parentProp2: + type: string diff --git a/demo/sidebars.ts b/demo/sidebars.ts index cc4e4255b..037e3c4cc 100644 --- a/demo/sidebars.ts +++ b/demo/sidebars.ts @@ -170,6 +170,20 @@ const sidebars: SidebarsConfig = { items: petstoreVersionSidebar, }, ], + + tests: [ + { + type: "category", + label: "Tests", + link: { + type: "generated-index", + title: "Tests", + description: "Various OpenAPI test cases", + slug: "/category/tests", + }, + items: require("./docs/tests/sidebar.js"), + }, + ], }; export default sidebars; From 2aafc8eeea57f2646e06b5cc36accb57646bfc7a Mon Sep 17 00:00:00 2001 From: Steven Serrata Date: Fri, 2 Aug 2024 12:10:47 -0500 Subject: [PATCH 6/8] hide allOf discriminator example --- demo/examples/tests/allOf.yaml | 74 +++++++++++++++++----------------- 1 file changed, 37 insertions(+), 37 deletions(-) diff --git a/demo/examples/tests/allOf.yaml b/demo/examples/tests/allOf.yaml index 2c2e7817e..76ca2ee82 100644 --- a/demo/examples/tests/allOf.yaml +++ b/demo/examples/tests/allOf.yaml @@ -200,43 +200,43 @@ paths: innerProp2: type: number - /allof-discriminator: - get: - tags: - - allOf - summary: allOf with Discriminator - description: | - Schema: - ```yaml - allOf: - - type: object - discriminator: - propertyName: type - properties: - type: - type: string - - type: object - properties: - specificProp: - type: string - ``` - responses: - "200": - description: Successful response - content: - application/json: - schema: - allOf: - - type: object - discriminator: - propertyName: type - properties: - type: - type: string - - type: object - properties: - specificProp: - type: string + # /allof-discriminator: + # get: + # tags: + # - allOf + # summary: allOf with Discriminator + # description: | + # Schema: + # ```yaml + # allOf: + # - type: object + # discriminator: + # propertyName: type + # properties: + # type: + # type: string + # - type: object + # properties: + # specificProp: + # type: string + # ``` + # responses: + # "200": + # description: Successful response + # content: + # application/json: + # schema: + # allOf: + # - type: object + # discriminator: + # propertyName: type + # properties: + # type: + # type: string + # - type: object + # properties: + # specificProp: + # type: string /allof-same-level-properties: get: From d58404cf139a4d4e2fea86ed834b21eb5597b0f8 Mon Sep 17 00:00:00 2001 From: Steven Serrata Date: Fri, 2 Aug 2024 12:14:03 -0500 Subject: [PATCH 7/8] fix linter issues --- .../src/markdown/createSchema.test.ts | 3 +++ 1 file changed, 3 insertions(+) diff --git a/packages/docusaurus-plugin-openapi-docs/src/markdown/createSchema.test.ts b/packages/docusaurus-plugin-openapi-docs/src/markdown/createSchema.test.ts index fcba9cc09..a9a4f964a 100644 --- a/packages/docusaurus-plugin-openapi-docs/src/markdown/createSchema.test.ts +++ b/packages/docusaurus-plugin-openapi-docs/src/markdown/createSchema.test.ts @@ -171,6 +171,7 @@ describe("createNodes", () => { // Could not resolve values for path:"properties.conflictingProp.type". They are probably incompatible. Values: // "string" // "number" + // eslint-disable-next-line jest/no-commented-out-tests // it("should handle conflicting properties in allOf schemas", async () => { // const schema: SchemaObject = { // allOf: [ @@ -205,6 +206,7 @@ describe("createNodes", () => { // Could not resolve values for path:"type". They are probably incompatible. Values: // "object" // "array" + // eslint-disable-next-line jest/no-commented-out-tests // it("should handle mixed data types in allOf schemas", async () => { // const schema: SchemaObject = { // allOf: [ @@ -275,6 +277,7 @@ describe("createNodes", () => { ).toMatchSnapshot(); }); + // eslint-disable-next-line jest/no-commented-out-tests // it("should handle discriminator with allOf schemas", async () => { // const schema: SchemaObject = { // allOf: [ From 858cc80a0e0a4e2a5b47a2531ec3b708998f78d8 Mon Sep 17 00:00:00 2001 From: Steven Serrata Date: Fri, 2 Aug 2024 12:45:21 -0500 Subject: [PATCH 8/8] define global tags --- demo/examples/tests/allOf.yaml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/demo/examples/tests/allOf.yaml b/demo/examples/tests/allOf.yaml index 76ca2ee82..6d5dd9ae6 100644 --- a/demo/examples/tests/allOf.yaml +++ b/demo/examples/tests/allOf.yaml @@ -3,6 +3,9 @@ info: title: AllOf Variations API description: Demonstrates various allOf schema combinations. version: 1.0.0 +tags: + - name: allOf + description: allOf tests paths: /multiple-allof-nested: get: