Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
22 changes: 16 additions & 6 deletions src/oas/__tests__/__snapshots__/service.test.ts.snap
Original file line number Diff line number Diff line change
Expand Up @@ -71,6 +71,7 @@ Object {
"tags": Array [
Object {
"description": "Everything about your Pets",
"extensions": Object {},
"externalDocs": Object {
"description": "Find out more",
"url": "http://swagger.io",
Expand All @@ -80,11 +81,13 @@ Object {
},
Object {
"description": "Access to Petstore orders",
"extensions": Object {},
"id": "tag-store",
"name": "store",
},
Object {
"description": "Operations about user",
"extensions": Object {},
"externalDocs": Object {
"description": "Find out more about our store",
"url": "http://swagger.io",
Expand All @@ -93,11 +96,13 @@ Object {
"name": "user",
},
Object {
"extensions": Object {
"x-service-tag-extension": Object {
"hello": "world",
},
},
"id": "tag-x-extension-in-tag",
"name": "x-extension-in-tag",
"x-service-tag-extension": Object {
"hello": "world",
},
},
],
"termsOfService": "http://swagger.io/terms/",
Expand Down Expand Up @@ -176,6 +181,7 @@ Object {
"tags": Array [
Object {
"description": "Everything about your Pets",
"extensions": Object {},
"externalDocs": Object {
"description": "Find out more",
"url": "http://swagger.io",
Expand All @@ -185,11 +191,13 @@ Object {
},
Object {
"description": "Access to Petstore orders",
"extensions": Object {},
"id": "tag-store",
"name": "store",
},
Object {
"description": "Operations about user",
"extensions": Object {},
"externalDocs": Object {
"description": "Find out more about our store",
"url": "http://swagger.io",
Expand All @@ -198,11 +206,13 @@ Object {
"name": "user",
},
Object {
"extensions": Object {
"x-service-tag-extension": Object {
"hello": "world",
},
},
"id": "tag-x-extension-in-tag",
"name": "x-extension-in-tag",
"x-service-tag-extension": Object {
"hello": "world",
},
},
],
"termsOfService": "http://swagger.io/terms/",
Expand Down
2 changes: 1 addition & 1 deletion src/oas/tags.ts
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ export const translateTagDefinition: TranslateFunction<
),

...toExternalDocs(tag.externalDocs),
...extensions,
extensions,
};
};

Expand Down
1 change: 1 addition & 0 deletions src/oas2/__tests__/__fixtures__/id/bundled.ts
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ export default {
// hash('tag-mutates')
id: 'tag-mutates',
name: 'mutates',
extensions: {},
},
],
extensions: {
Expand Down
6 changes: 4 additions & 2 deletions src/oas2/__tests__/bundle.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -313,8 +313,10 @@ describe('bundleOas2Service', () => {
{
id: 'tag-service-tag-extension',
name: 'service-tag-extension',
'x-service-tag-extension': {
hello: 'world',
extensions: {
'x-service-tag-extension': {
hello: 'world',
},
},
},
],
Expand Down
1 change: 1 addition & 0 deletions src/oas3/__tests__/__fixtures__/id/bundled.ts
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ export default {
// hash('tag-mutates')
id: 'tag-mutates',
name: 'mutates',
extensions: {},
},
],
components: {
Expand Down
1 change: 1 addition & 0 deletions src/oas3/__tests__/__fixtures__/id/legacy.ts
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,7 @@ export default [
// hash(`tag-${tag.name}`)
id: 'tag-mutates',
name: 'mutates',
extensions: {},
},
],
extensions: {
Expand Down
6 changes: 4 additions & 2 deletions src/oas3/__tests__/bundle.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -930,8 +930,10 @@ describe('bundleOas3Service', () => {
{
id: 'tag-service-tag-extension',
name: 'service-tag-extension',
'x-service-tag-extension': {
hello: 'world',
extensions: {
'x-service-tag-extension': {
hello: 'world',
},
},
},
],
Expand Down