From e1759986c0039dc1c040358cbf00ce0e6cad79e4 Mon Sep 17 00:00:00 2001 From: Kiri111enz Date: Tue, 30 Jan 2024 15:11:19 +0300 Subject: [PATCH] prettier fixes --- src/__tests__/examples/array.test.ts | 52 ++++++++++++++-------------- src/includer/traverse/tables.ts | 4 +-- 2 files changed, 28 insertions(+), 28 deletions(-) diff --git a/src/__tests__/examples/array.test.ts b/src/__tests__/examples/array.test.ts index 7a220ce..37896b1 100644 --- a/src/__tests__/examples/array.test.ts +++ b/src/__tests__/examples/array.test.ts @@ -110,16 +110,16 @@ describe('openapi project with examples', () => { oneOf: [ { type: 'string', - default: 's' + default: 's', }, { type: 'integer', - default: '0' - } - ] + default: '0', + }, + ], }, - } - } + }, + }, }, }) .response(200, { @@ -153,8 +153,8 @@ describe('openapi project with examples', () => { c: { type: 'string', default: 'c' - } - } + }, + }, }, { type: 'object', @@ -162,13 +162,13 @@ describe('openapi project with examples', () => { d: { type: 'string', default: 'd' - } - } - } - ] + }, + }, + }, + ], }, - } - } + }, + }, }, }) .response(200, { @@ -204,10 +204,10 @@ describe('openapi project with examples', () => { a: { type: 'string', default: 'a' - } - } - } - ] + }, + }, + }, + ], }, { allOf: [ @@ -217,15 +217,15 @@ describe('openapi project with examples', () => { b: { type: 'string', default: 'b' - } - } - } - ] - } - ] + }, + }, + }, + ], + }, + ], }, - } - } + }, + }, }, }) .response(200, { diff --git a/src/includer/traverse/tables.ts b/src/includer/traverse/tables.ts index 035823c..4153e9e 100644 --- a/src/includer/traverse/tables.ts +++ b/src/includer/traverse/tables.ts @@ -351,8 +351,8 @@ function prepareSampleElement( ); } if (schema.items.oneOf) { - return schema.items.oneOf - .map((item) => prepareSampleElement(key, item, isRequired(key, schema), downCallstack)); + return schema.items.oneOf.map((item) => + prepareSampleElement(key, item, isRequired(key, schema), downCallstack)); } return [ prepareSampleElement(key, schema.items, isRequired(key, schema), downCallstack),