From 7922f62048a7b073f3b3c307cc879063ba87c3f0 Mon Sep 17 00:00:00 2001 From: Matthias Osswald Date: Tue, 5 May 2020 15:08:17 +0200 Subject: [PATCH] Review feedback --- .../validation/schema/__helper__/extension.js | 40 +++++++++---------- 1 file changed, 20 insertions(+), 20 deletions(-) diff --git a/test/lib/validation/schema/__helper__/extension.js b/test/lib/validation/schema/__helper__/extension.js index 51a3276b9..31aaa4466 100644 --- a/test/lib/validation/schema/__helper__/extension.js +++ b/test/lib/validation/schema/__helper__/extension.js @@ -22,7 +22,6 @@ module.exports = { test(`kind: extension / type: ${type} basic (${specVersion})`, async (t) => { await assertValidation(t, Object.assign({ "specVersion": specVersion, - "kind": "extension", "type": type, "metadata": { "name": "my-" + type @@ -33,7 +32,6 @@ module.exports = { test(`kind: extension / type: ${type} additionalProperties (${specVersion})`, async (t) => { await assertValidation(t, Object.assign({ "specVersion": specVersion, - "kind": "extension", "type": type, "metadata": { "name": "my-" + type @@ -50,24 +48,26 @@ module.exports = { }]); }); - test(`${type} Invalid configuration: Additional property (${specVersion})`, async (t) => { - await assertValidation(t, Object.assign( { - "specVersion": specVersion, - "type": type, - "metadata": { - "name": "my-" + type - }, - "notAllowed": true - }, additionalConfiguration), [{ - dataPath: "", - keyword: "additionalProperties", - message: "should NOT have additional properties", - params: { - additionalProperty: "notAllowed", - }, - schemaPath: specVersion === "2.1" ? "#/then/additionalProperties" : "#/else/additionalProperties" - }]); - }); + test(`kind: extension / type: ${type} Invalid configuration: Additional property (${specVersion})`, + async (t) => { + await assertValidation(t, Object.assign( { + "specVersion": specVersion, + "type": type, + "metadata": { + "name": "my-" + type + }, + "notAllowed": true + }, additionalConfiguration), [{ + dataPath: "", + keyword: "additionalProperties", + message: "should NOT have additional properties", + params: { + additionalProperty: "notAllowed", + }, + schemaPath: + specVersion === "2.1" ? "#/then/additionalProperties" : "#/else/additionalProperties" + }]); + }); }); } };