From 3d4fbad1e39f7cbb37643864b8229aa4116ce07c Mon Sep 17 00:00:00 2001 From: mo khan Date: Wed, 15 Jan 2020 14:51:53 -0700 Subject: Combine schema into a single file --- spec/fixtures/schema/v2.0.json | 48 +++++++++++++++++++++++++++++-- spec/fixtures/schema/v2.0_dependency.json | 27 ----------------- 2 files changed, 46 insertions(+), 29 deletions(-) delete mode 100644 spec/fixtures/schema/v2.0_dependency.json diff --git a/spec/fixtures/schema/v2.0.json b/spec/fixtures/schema/v2.0.json index 3377a9d..712143b 100644 --- a/spec/fixtures/schema/v2.0.json +++ b/spec/fixtures/schema/v2.0.json @@ -8,8 +8,52 @@ ], "properties": { "version": { "type": "string" }, - "licenses": { "type": "array" }, - "dependencies": { "$ref": "v2.0_dependency.json" } + "licenses": { + "type": "array", + "items": { + "type": "object", + "required": [ + "id", + "name", + "url" + ], + "properties": { + "id": { "type": "string" }, + "name": { "type": "string" }, + "url": { "type": "uri" } + } + } + }, + "dependencies": { + "type": "array", + "items": { + "type": "object", + "required": [ + "name", + "url", + "description", + "paths", + "licenses" + ], + "properties": { + "name": { "type": "string" }, + "url": { "type": "uri" }, + "description": { "type": "string" }, + "paths": { + "type": "array", + "items": { + "type": "string" + } + }, + "licenses": { + "type": "array", + "items": { + "type": "string" + } + } + } + } + } }, "additionalProperties": false } diff --git a/spec/fixtures/schema/v2.0_dependency.json b/spec/fixtures/schema/v2.0_dependency.json deleted file mode 100644 index fcd96d7..0000000 --- a/spec/fixtures/schema/v2.0_dependency.json +++ /dev/null @@ -1,27 +0,0 @@ -{ - "type": "array", - "required": [ - "name", - "url", - "description", - "paths", - "licenses" - ], - "properties": { - "name": { "type": "string" }, - "url": { "type": "uri" }, - "description": { "type": "string" }, - "paths": { - "type": "array", - "items": { - "type": "string" - } - }, - "licenses": { - "type": "array", - "items": { - "type": "string" - } - } - } -} -- cgit v1.2.3