aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorEverett Hildenbrandt <hildenb2@illinois.edu>2018-05-30 04:25:42 +0800
committerEverett Hildenbrandt <hildenb2@illinois.edu>2018-05-31 22:37:30 +0800
commit60512bfb9a06399d8eeb7aab6330960efe968642 (patch)
tree5f0a800dff38d70bf2ddef51229a7e84abc9b1da
parentec525a8c13523d3f73f2e63a9e68725a354f1c8d (diff)
downloadtangerine-tests-60512bfb9a06399d8eeb7aab6330960efe968642.tar
tangerine-tests-60512bfb9a06399d8eeb7aab6330960efe968642.tar.gz
tangerine-tests-60512bfb9a06399d8eeb7aab6330960efe968642.tar.bz2
tangerine-tests-60512bfb9a06399d8eeb7aab6330960efe968642.tar.lz
tangerine-tests-60512bfb9a06399d8eeb7aab6330960efe968642.tar.xz
tangerine-tests-60512bfb9a06399d8eeb7aab6330960efe968642.tar.zst
tangerine-tests-60512bfb9a06399d8eeb7aab6330960efe968642.zip
JSONSchema/bc-schema: fix schema for blockchaintests
-rw-r--r--JSONSchema/bc-schema.json49
1 files changed, 31 insertions, 18 deletions
diff --git a/JSONSchema/bc-schema.json b/JSONSchema/bc-schema.json
index 3df6ffdf2..35625af8c 100644
--- a/JSONSchema/bc-schema.json
+++ b/JSONSchema/bc-schema.json
@@ -1,5 +1,9 @@
{
"definitions": {
+ "BadHexData": {
+ "pattern": "^0x[0-9a-zA-Z]*$",
+ "type": "string"
+ },
"Block": {
"additionalProperties": false,
"properties": {
@@ -40,7 +44,7 @@
"type": "string"
},
"rlp": {
- "$ref": "#/definitions/HexData"
+ "$ref": "#/definitions/BadHexData"
},
"transactions": {
"items": {
@@ -179,7 +183,7 @@
"storage": {
"additionalProperties": false,
"patternProperties": {
- "^0x[0-9a-f]+": {
+ "^0x[0-9a-f]*": {
"$ref": "#/definitions/HexData",
"description": "storage key with 0x. data is HexData"
}
@@ -266,12 +270,6 @@
},
"patternProperties": {
"^.*$": {
- "postState": {
- "$ref": "#/definitions/TransactionResults"
- },
- "pre": {
- "$ref": "#/definitions/TransactionResults"
- },
"properties": {
"blocks": {
"items": {
@@ -284,18 +282,33 @@
},
"genesisRLP": {
"$ref": "#/definitions/ConfusedHexType"
+ },
+ "postState": {
+ "patternProperties": {
+ "^0x[0-9a-f]*": {
+ "$ref": "#/definitions/PreStateAccount",
+ "description": "poststate account address with 0x prefix"
+ }
+ }
+ },
+ "pre": {
+ "patternProperties": {
+ "^0x[0-9a-f]*": {
+ "$ref": "#/definitions/PreStateAccount",
+ "description": "prestate account address with 0x prefix"
+ }
+ }
}
},
+ "required": [
+ "postState",
+ "pre",
+ "network",
+ "lastblockhash",
+ "blocks",
+ "genesisBlockHeader"
+ ],
"type": "object"
- },
- "required": [
- "postState",
- "pre",
- "network",
- "lastblockhash",
- "blocks",
- "genesisRLP",
- "genesisBlockHeader"
- ]
+ }
}
} \ No newline at end of file