Bump Portal test vectors and re-activate skipped tests (#2515)
This commit is contained in:
parent
08bbb0079f
commit
84ce0c912e
|
@ -247,8 +247,7 @@ procSuite "Portal testnet tests":
|
||||||
headerFile =
|
headerFile =
|
||||||
"./vendor/portal-spec-tests/tests/mainnet/history/headers/1000001-1000010.e2s"
|
"./vendor/portal-spec-tests/tests/mainnet/history/headers/1000001-1000010.e2s"
|
||||||
accumulatorFile =
|
accumulatorFile =
|
||||||
"./vendor/portal-spec-tests/tests/mainnet/history/accumulator/epoch-accumulator-00122.ssz"
|
"./vendor/portal-spec-tests/tests/mainnet/history/accumulator/epoch-record-00122.ssz"
|
||||||
# TODO: rename
|
|
||||||
blockDataFile = "./fluffy/tests/blocks/mainnet_blocks_1000001_1000010.json"
|
blockDataFile = "./fluffy/tests/blocks/mainnet_blocks_1000001_1000010.json"
|
||||||
|
|
||||||
let
|
let
|
||||||
|
|
|
@ -26,21 +26,19 @@ suite "History Block Proofs - Bellatrix":
|
||||||
"./vendor/portal-spec-tests/tests/mainnet/history/headers_with_proof/block_proofs_bellatrix/"
|
"./vendor/portal-spec-tests/tests/mainnet/history/headers_with_proof/block_proofs_bellatrix/"
|
||||||
historicalRoots = loadHistoricalRoots()
|
historicalRoots = loadHistoricalRoots()
|
||||||
|
|
||||||
# TODO: reactivate when test vectors PR gets merged
|
for kind, path in walkDir(testsPath):
|
||||||
skip()
|
if kind == pcFile and path.splitFile.ext == ".yaml":
|
||||||
# for kind, path in walkDir(testsPath):
|
let
|
||||||
# if kind == pcFile and path.splitFile.ext == ".yaml":
|
testProof = YamlTestProofBellatrix.loadFromYaml(path).valueOr:
|
||||||
# let
|
raiseAssert "Cannot read test vector: " & error
|
||||||
# testProof = YamlTestProofBellatrix.loadFromYaml(path).valueOr:
|
|
||||||
# raiseAssert "Cannot read test vector: " & error
|
|
||||||
|
|
||||||
# blockHash = BlockHash.fromHex(testProof.execution_block_header)
|
blockHash = BlockHash.fromHex(testProof.execution_block_header)
|
||||||
# blockProof = BeaconChainBlockProof(
|
blockProof = BeaconChainBlockProof(
|
||||||
# beaconBlockProof: array[11, Digest].fromHex(testProof.beacon_block_proof),
|
beaconBlockProof: array[11, Digest].fromHex(testProof.beacon_block_proof),
|
||||||
# beaconBlockRoot: Digest.fromHex(testProof.beacon_block_root),
|
beaconBlockRoot: Digest.fromHex(testProof.beacon_block_root),
|
||||||
# historicalRootsProof:
|
historicalRootsProof:
|
||||||
# array[14, Digest].fromHex(testProof.historical_roots_proof),
|
array[14, Digest].fromHex(testProof.historical_roots_proof),
|
||||||
# slot: Slot(testProof.slot),
|
slot: Slot(testProof.slot),
|
||||||
# )
|
)
|
||||||
|
|
||||||
# check verifyProof(historicalRoots, blockProof, blockHash)
|
check verifyProof(historicalRoots, blockProof, blockHash)
|
||||||
|
|
|
@ -55,23 +55,21 @@ suite "History Block Proofs - Capella":
|
||||||
historicalSummaries = readHistoricalSummaries(historicalSummaries_path).valueOr:
|
historicalSummaries = readHistoricalSummaries(historicalSummaries_path).valueOr:
|
||||||
raiseAssert "Cannot read historical summaries: " & error
|
raiseAssert "Cannot read historical summaries: " & error
|
||||||
|
|
||||||
# TODO: reactivate when test vectors PR gets merged
|
for kind, path in walkDir(testsPath):
|
||||||
skip()
|
if kind == pcFile and path.splitFile.ext == ".yaml":
|
||||||
# for kind, path in walkDir(testsPath):
|
let
|
||||||
# if kind == pcFile and path.splitFile.ext == ".yaml":
|
testProof = YamlTestProof.loadFromYaml(path).valueOr:
|
||||||
# let
|
raiseAssert "Cannot read test vector: " & error
|
||||||
# testProof = YamlTestProof.loadFromYaml(path).valueOr:
|
|
||||||
# raiseAssert "Cannot read test vector: " & error
|
|
||||||
|
|
||||||
# blockHash = BlockHash.fromHex(testProof.execution_block_header)
|
blockHash = BlockHash.fromHex(testProof.execution_block_header)
|
||||||
# blockProof = BeaconChainBlockProof(
|
blockProof = BeaconChainBlockProof(
|
||||||
# beaconBlockProof: array[11, Digest].fromHex(testProof.beacon_block_proof),
|
beaconBlockProof: array[11, Digest].fromHex(testProof.beacon_block_proof),
|
||||||
# beaconBlockRoot: Digest.fromHex(testProof.beacon_block_root),
|
beaconBlockRoot: Digest.fromHex(testProof.beacon_block_root),
|
||||||
# historicalSummariesProof:
|
historicalSummariesProof:
|
||||||
# array[13, Digest].fromHex(testProof.historical_summaries_proof),
|
array[13, Digest].fromHex(testProof.historical_summaries_proof),
|
||||||
# slot: Slot(testProof.slot),
|
slot: Slot(testProof.slot),
|
||||||
# )
|
)
|
||||||
|
|
||||||
# check verifyProof(
|
check verifyProof(
|
||||||
# historicalSummaries, blockProof, blockHash, networkData.metadata.cfg
|
historicalSummaries, blockProof, blockHash, networkData.metadata.cfg
|
||||||
# )
|
)
|
||||||
|
|
|
@ -27,8 +27,7 @@ suite "History Content Encodings":
|
||||||
headerFile =
|
headerFile =
|
||||||
"./vendor/portal-spec-tests/tests/mainnet/history/headers/1000001-1000010.e2s"
|
"./vendor/portal-spec-tests/tests/mainnet/history/headers/1000001-1000010.e2s"
|
||||||
accumulatorFile =
|
accumulatorFile =
|
||||||
"./vendor/portal-spec-tests/tests/mainnet/history/accumulator/epoch-accumulator-00122.ssz"
|
"./vendor/portal-spec-tests/tests/mainnet/history/accumulator/epoch-record-00122.ssz"
|
||||||
# TODO: rename
|
|
||||||
headersWithProofFile =
|
headersWithProofFile =
|
||||||
"./vendor/portal-spec-tests/tests/mainnet/history/headers_with_proof/1000001-1000010.json"
|
"./vendor/portal-spec-tests/tests/mainnet/history/headers_with_proof/1000001-1000010.json"
|
||||||
|
|
||||||
|
|
|
@ -1 +1 @@
|
||||||
Subproject commit af2360565c4ed5342bb5533bace4e2b9712e0d1b
|
Subproject commit 4254dac8ce1cbe28fc4704d92aa6809c73451c20
|
Loading…
Reference in New Issue