From 505c369f2782af6e3026670af744b9e7044868bb Mon Sep 17 00:00:00 2001 From: Graham Esau Date: Mon, 7 Oct 2019 20:35:40 +0100 Subject: [PATCH] Regenerate integration test expected json --- schemars/tests/expected/chrono-types.json | 16 +++--- .../tests/expected/property-name-struct.json | 12 ++--- schemars/tests/expected/remote_derive.json | 50 +++++++++---------- .../tests/expected/schema-name-custom.json | 24 ++++----- .../tests/expected/schema-name-default.json | 24 ++++----- .../tests/expected/skip_enum_variants.json | 8 +-- .../tests/expected/skip_struct_fields.json | 10 ++-- schemars/tests/expected/struct-normal.json | 10 ++-- 8 files changed, 77 insertions(+), 77 deletions(-) diff --git a/schemars/tests/expected/chrono-types.json b/schemars/tests/expected/chrono-types.json index b96b00c..6e289bd 100644 --- a/schemars/tests/expected/chrono-types.json +++ b/schemars/tests/expected/chrono-types.json @@ -2,6 +2,13 @@ "$schema": "http://json-schema.org/draft-07/schema#", "title": "ChronoTypes", "type": "object", + "required": [ + "date_time", + "naive_date", + "naive_date_time", + "naive_time", + "weekday" + ], "properties": { "date_time": { "type": "string", @@ -31,12 +38,5 @@ "Sun" ] } - }, - "required": [ - "date_time", - "naive_date", - "naive_date_time", - "naive_time", - "weekday" - ] + } } \ No newline at end of file diff --git a/schemars/tests/expected/property-name-struct.json b/schemars/tests/expected/property-name-struct.json index 1aa6e78..aa708fd 100644 --- a/schemars/tests/expected/property-name-struct.json +++ b/schemars/tests/expected/property-name-struct.json @@ -2,6 +2,11 @@ "$schema": "http://json-schema.org/draft-07/schema#", "title": "MyStruct", "type": "object", + "required": [ + "camelCase", + "new_name_1", + "new_name_2" + ], "properties": { "camelCase": { "type": "integer", @@ -15,10 +20,5 @@ "type": "integer", "format": "int32" } - }, - "required": [ - "camelCase", - "new_name_1", - "new_name_2" - ] + } } \ No newline at end of file diff --git a/schemars/tests/expected/remote_derive.json b/schemars/tests/expected/remote_derive.json index f91ad59..a19fc28 100644 --- a/schemars/tests/expected/remote_derive.json +++ b/schemars/tests/expected/remote_derive.json @@ -2,6 +2,31 @@ "$schema": "http://json-schema.org/draft-07/schema#", "title": "Process", "type": "object", + "definitions": { + "DurationDef": { + "type": "object", + "required": [ + "nanos", + "secs" + ], + "properties": { + "nanos": { + "type": "integer", + "format": "int32" + }, + "secs": { + "type": "integer", + "format": "int64" + } + } + } + }, + "required": [ + "command_line", + "system_cpu_time", + "user_cpu_time", + "wall_time" + ], "properties": { "command_line": { "type": "string" @@ -15,30 +40,5 @@ "wall_time": { "$ref": "#/definitions/DurationDef" } - }, - "required": [ - "command_line", - "system_cpu_time", - "user_cpu_time", - "wall_time" - ], - "definitions": { - "DurationDef": { - "type": "object", - "properties": { - "nanos": { - "type": "integer", - "format": "int32" - }, - "secs": { - "type": "integer", - "format": "int64" - } - }, - "required": [ - "nanos", - "secs" - ] - } } } \ No newline at end of file diff --git a/schemars/tests/expected/schema-name-custom.json b/schemars/tests/expected/schema-name-custom.json index 5298969..362c772 100644 --- a/schemars/tests/expected/schema-name-custom.json +++ b/schemars/tests/expected/schema-name-custom.json @@ -2,6 +2,18 @@ "$schema": "http://json-schema.org/draft-07/schema#", "title": "a-new-name-Array_Of_String-Integer-Integer", "type": "object", + "definitions": { + "another-new-name": { + "type": "object" + } + }, + "required": [ + "inner", + "t", + "u", + "v", + "w" + ], "properties": { "inner": { "$ref": "#/definitions/another-new-name" @@ -22,17 +34,5 @@ "type": "string" } } - }, - "required": [ - "inner", - "t", - "u", - "v", - "w" - ], - "definitions": { - "another-new-name": { - "type": "object" - } } } \ No newline at end of file diff --git a/schemars/tests/expected/schema-name-default.json b/schemars/tests/expected/schema-name-default.json index 88c95a4..5742228 100644 --- a/schemars/tests/expected/schema-name-default.json +++ b/schemars/tests/expected/schema-name-default.json @@ -2,6 +2,18 @@ "$schema": "http://json-schema.org/draft-07/schema#", "title": "MyStruct_For_Integer_And_Null_And_Boolean_And_Array_Of_String", "type": "object", + "definitions": { + "MySimpleStruct": { + "type": "object" + } + }, + "required": [ + "inner", + "t", + "u", + "v", + "w" + ], "properties": { "inner": { "$ref": "#/definitions/MySimpleStruct" @@ -22,17 +34,5 @@ "type": "string" } } - }, - "required": [ - "inner", - "t", - "u", - "v", - "w" - ], - "definitions": { - "MySimpleStruct": { - "type": "object" - } } } \ No newline at end of file diff --git a/schemars/tests/expected/skip_enum_variants.json b/schemars/tests/expected/skip_enum_variants.json index f15342f..6ce7aca 100644 --- a/schemars/tests/expected/skip_enum_variants.json +++ b/schemars/tests/expected/skip_enum_variants.json @@ -9,15 +9,15 @@ }, { "type": "object", + "required": [ + "Included1" + ], "properties": { "Included1": { "type": "number", "format": "float" } - }, - "required": [ - "Included1" - ] + } } ] } \ No newline at end of file diff --git a/schemars/tests/expected/skip_struct_fields.json b/schemars/tests/expected/skip_struct_fields.json index c03f4e9..e47c0bf 100644 --- a/schemars/tests/expected/skip_struct_fields.json +++ b/schemars/tests/expected/skip_struct_fields.json @@ -2,6 +2,10 @@ "$schema": "http://json-schema.org/draft-07/schema#", "title": "MyStruct", "type": "object", + "required": [ + "included1", + "included2" + ], "properties": { "included1": { "type": "number", @@ -10,9 +14,5 @@ "included2": { "type": "null" } - }, - "required": [ - "included1", - "included2" - ] + } } \ No newline at end of file diff --git a/schemars/tests/expected/struct-normal.json b/schemars/tests/expected/struct-normal.json index 9275eaa..98a5e36 100644 --- a/schemars/tests/expected/struct-normal.json +++ b/schemars/tests/expected/struct-normal.json @@ -2,6 +2,10 @@ "$schema": "http://json-schema.org/draft-07/schema#", "title": "Struct", "type": "object", + "required": [ + "bar", + "foo" + ], "properties": { "bar": { "type": "boolean" @@ -10,9 +14,5 @@ "type": "integer", "format": "int32" } - }, - "required": [ - "bar", - "foo" - ] + } } \ No newline at end of file