Skip to content

Commit 85987dc

Browse files
committed
feat: Review
1 parent b367ca2 commit 85987dc

File tree

3 files changed

+9
-9
lines changed

3 files changed

+9
-9
lines changed

test/compatibility-suites/openapi/templates/reference-object-31.template.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,7 @@ export function runReferenceObjectTests(suiteId: string, refPath: JsonPath, comp
5858

5959
test(`Change referenced ${overridenField} when overridden exists`, async () => {
6060
const testId = `change-referenced-${overridenField}-when-overridden-exists`
61-
const result = await compareFiles(suiteId, testId)
62-
expect(result.length).toEqual(0)
61+
const diffs = await compareFiles(suiteId, testId)
62+
expect(diffs).toBeEmpty()
6363
})
6464
}

test/compatibility-suites/openapi/templates/schema.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1101,8 +1101,8 @@ export function runCommonSchemaTests(suiteId: string, commonPath: JsonPath): voi
11011101
test('Update definition of free-form object', async () => {
11021102

11031103
const testId = 'update-definition-of-free-form-object'
1104-
const result = await compareFiles(suiteId, testId)
1105-
expect(result.length).toEqual(0)
1104+
const diffs = await compareFiles(suiteId, testId)
1105+
expect(diffs).toBeEmpty()
11061106
})
11071107

11081108
test('Add non-boolean additionalProperties', async () => {

test/compatibility-suites/openapi/templates/sibling-properties-schema.template.ts

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ import { diffsMatcher } from '../../../helper/matchers'
66
const COMPONENTS_SCHEMAS = ['components', 'schemas']
77

88
export function runResponseSiblingPropertiesSchema(suiteId: string, commonPath: JsonPath): void {
9-
runTests(suiteId, commonPath)
9+
runCommonRefSiblingPropertiesTests(suiteId, commonPath)
1010

1111
test('Change referenced enum when sibling exists for ref', async () => {
1212
const testId = 'change-referenced-enum-when-sibling-exists-for-ref'
@@ -38,7 +38,7 @@ export function runResponseSiblingPropertiesSchema(suiteId: string, commonPath:
3838
}
3939

4040
export function runSiblingPropertiesSchema(suiteId: string, commonPath: JsonPath): void {
41-
runTests(suiteId, commonPath)
41+
runCommonRefSiblingPropertiesTests(suiteId, commonPath)
4242

4343
test('Change referenced enum when sibling exists for ref', async () => {
4444
const testId = 'change-referenced-enum-when-sibling-exists-for-ref'
@@ -69,7 +69,7 @@ export function runSiblingPropertiesSchema(suiteId: string, commonPath: JsonPath
6969
})
7070
}
7171

72-
function runTests(suiteId: string, commonPath: JsonPath): void {
72+
function runCommonRefSiblingPropertiesTests(suiteId: string, commonPath: JsonPath): void {
7373
test('Add sibling description for ref', async () => {
7474
const testId = 'add-sibling-description-for-ref'
7575
const result = await compareFiles(suiteId, testId)
@@ -85,7 +85,7 @@ function runTests(suiteId: string, commonPath: JsonPath): void {
8585

8686
test('Change sibling enum for ref', async () => {
8787
const testId = 'change-sibling-enum-for-ref'
88-
const result = await compareFiles(suiteId, testId)
89-
expect(result.length).toEqual(0)
88+
const diffs = await compareFiles(suiteId, testId)
89+
expect(diffs).toBeEmpty()
9090
})
9191
}

0 commit comments

Comments
 (0)