Skip to content

Commit

Permalink
update json schema for invalid blockchain tests
Browse files Browse the repository at this point in the history
  • Loading branch information
winsvega committed Jan 10, 2020
1 parent 2948f43 commit 64a0df4
Show file tree
Hide file tree
Showing 5 changed files with 33 additions and 226 deletions.
52 changes: 29 additions & 23 deletions JSONSchema/bc-filler-schema.json
Original file line number Diff line number Diff line change
@@ -1,17 +1,5 @@
{
"definitions": {
"BlockchainExpectSection": {
"additionalProperties": false,
"properties": {
"network": {
"$ref": "#/definitions/Networks"
},
"result": {
"$ref": "#/definitions/AccountMap"
}
},
"type": "array"
},
"BadHexData": {
"pattern": "^0x[0-9a-zA-Z]*$",
"type": "string"
Expand Down Expand Up @@ -91,6 +79,9 @@
"difficulty": {
"$ref": "#/definitions/IntegerOrConfusedHex"
},
"expectException": {
"type": "object"
},
"extraData": {
"$ref": "#/definitions/HexMaybePrefixOrEmpty"
},
Expand Down Expand Up @@ -129,6 +120,9 @@
},
"uncleHash": {
"$ref": "#/definitions/IntegerOrConfusedHex"
},
"updatePow": {
"$ref": "#/definitions/IntegerOrConfusedHex"
}
}
},
Expand All @@ -148,6 +142,18 @@
}
}
},
"BlockchainExpectSection": {
"additionalProperties": false,
"properties": {
"network": {
"$ref": "#/definitions/Networks"
},
"result": {
"$ref": "#/definitions/AccountMap"
}
},
"type": "array"
},
"NullSenderTransaction": {
"additionalProperties": true,
"not": {
Expand Down Expand Up @@ -236,9 +242,6 @@
],
"type": "object"
},
"sealEngine": {
"$ref": "#/definitions/SealEngineType"
},
"Transaction": {
"additionalProperties": true,
"not": {
Expand Down Expand Up @@ -320,6 +323,9 @@
]
}
]
},
"sealEngine": {
"$ref": "#/definitions/SealEngineType"
}
},
"patternProperties": {
Expand All @@ -331,25 +337,25 @@
},
"type": "array"
},
"network": {
"type": "string"
},
"expect": {
"oneOf": [
"oneOf": [
{
"$ref": "#/definitions/AccountMap"
},
{
"$ref": "#/definitions/BlockchainExpectSection"
}
]
]
},
"genesisBlockHeader": {
"$ref": "#/definitions/BlockHeader"
},
"genesisRLP": {
"$ref": "#/definitions/ConfusedHexType"
},
"network": {
"type": "string"
},
"pre": {
"patternProperties": {
"^0x[0-9a-f]*": {
Expand All @@ -358,9 +364,9 @@
}
}
},
"sealEngine": {
"$ref": "#/definitions/SealEngineType"
}
"sealEngine": {
"$ref": "#/definitions/SealEngineType"
}
},
"required": [
"pre",
Expand Down
3 changes: 3 additions & 0 deletions JSONSchema/bc-schema.json
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,9 @@
"comment": {
"type": "string"
},
"expectException": {
"type": "string"
},
"expectExceptionALL": {
"type": "string"
},
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@
{
"blockHeader" : {
"uncleHash" : "0xbd1aca7ed975e1b827350c9e167f19b7b28fb3d55339e51082e4327bc318fb5a",
"stateRoot" : "0xdd6283d3d1cdb05ccb389b62ae449408dddcba54fd27d8fed4e5295875ba46f7",
"stateRoot" : "0xdd6283d3d1cdb05ccb389b62ae449408dddcba54fd27d8fed4e5295875ba46f7"
},
"transactions" : [
{
Expand Down

This file was deleted.

This file was deleted.

0 comments on commit 64a0df4

Please sign in to comment.