Skip to content

Commit 7ca8c05

Browse files
committed
schemas: common result enum
1 parent 7601e63 commit 7ca8c05

32 files changed

+41
-216
lines changed

schemas/aead_test_schema_v1.json

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -76,13 +76,7 @@
7676
"description": "the authentication tag"
7777
},
7878
"result": {
79-
"type": "string",
80-
"description": "Test result",
81-
"enum": [
82-
"valid",
83-
"invalid",
84-
"acceptable"
85-
]
79+
"$ref": "common.json#/definitions/Result"
8680
},
8781
"flags": {
8882
"type": "array",

schemas/common.json

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -53,6 +53,15 @@
5353
},
5454
"required": ["bugType"],
5555
"additionalProperties": false
56+
},
57+
"Result": {
58+
"type": "string",
59+
"description": "Test vector result",
60+
"enum": [
61+
"valid",
62+
"invalid",
63+
"acceptable"
64+
]
5665
}
5766
}
5867
}

schemas/daead_test_schema_v1.json

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -58,13 +58,7 @@
5858
"description": "the ciphertext including tag"
5959
},
6060
"result": {
61-
"type": "string",
62-
"description": "Test result",
63-
"enum": [
64-
"valid",
65-
"invalid",
66-
"acceptable"
67-
]
61+
"$ref": "common.json#/definitions/Result"
6862
},
6963
"flags": {
7064
"type": "array",

schemas/ec_curve_test_schema.json

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -126,13 +126,7 @@
126126
"description": "Cofactor of the curve"
127127
},
128128
"result": {
129-
"type": "string",
130-
"description": "Test result",
131-
"enum": [
132-
"valid",
133-
"invalid",
134-
"acceptable"
135-
]
129+
"$ref": "common.json#/definitions/Result"
136130
}
137131
},
138132
"required": [

schemas/ecdh_ecpoint_test_schema_v1.json

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -58,13 +58,7 @@
5858
"description": "The shared secret key"
5959
},
6060
"result": {
61-
"type": "string",
62-
"description": "Test result",
63-
"enum": [
64-
"valid",
65-
"invalid",
66-
"acceptable"
67-
]
61+
"$ref": "common.json#/definitions/Result"
6862
},
6963
"flags": {
7064
"type": "array",

schemas/ecdh_pem_test_schema_v1.json

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -58,13 +58,7 @@
5858
"description": "The shared secret key"
5959
},
6060
"result": {
61-
"type": "string",
62-
"description": "Test result",
63-
"enum": [
64-
"valid",
65-
"invalid",
66-
"acceptable"
67-
]
61+
"$ref": "common.json#/definitions/Result"
6862
},
6963
"flags": {
7064
"type": "array",

schemas/ecdh_test_schema_v1.json

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -58,13 +58,7 @@
5858
"description": "The shared secret key"
5959
},
6060
"result": {
61-
"type": "string",
62-
"description": "Test result",
63-
"enum": [
64-
"valid",
65-
"invalid",
66-
"acceptable"
67-
]
61+
"$ref": "common.json#/definitions/Result"
6862
},
6963
"flags": {
7064
"type": "array",

schemas/ecdh_webcrypto_test_schema_v1.json

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -56,13 +56,7 @@
5656
"description": "The shared secret key"
5757
},
5858
"result": {
59-
"type": "string",
60-
"description": "Test result",
61-
"enum": [
62-
"valid",
63-
"invalid",
64-
"acceptable"
65-
]
59+
"$ref": "common.json#/definitions/Result"
6660
},
6761
"flags": {
6862
"type": "array",

schemas/hkdf_test_schema_v1.json

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -62,13 +62,7 @@
6262
"description": "the generated bytes (output key material)"
6363
},
6464
"result": {
65-
"type": "string",
66-
"description": "Test result",
67-
"enum": [
68-
"valid",
69-
"invalid",
70-
"acceptable"
71-
]
65+
"$ref": "common.json#/definitions/Result"
7266
},
7367
"flags": {
7468
"type": "array",

schemas/ind_cpa_test_schema_v1.json

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -62,13 +62,7 @@
6262
"description": "the raw ciphertext (without IV)"
6363
},
6464
"result": {
65-
"type": "string",
66-
"description": "Test result",
67-
"enum": [
68-
"valid",
69-
"invalid",
70-
"acceptable"
71-
]
65+
"$ref": "common.json#/definitions/Result"
7266
},
7367
"flags": {
7468
"type": "array",

0 commit comments

Comments
 (0)