update attestations and voluntary exit operations test to 0.10.1
This commit is contained in:
parent
45dd12cf3f
commit
9748b2606e
|
@ -66,18 +66,27 @@ template runTest(testName: string, identifier: untyped) =
|
|||
`testImpl _ operations_attestations _ identifier`()
|
||||
|
||||
suite "Official - Operations - Attestations " & preset():
|
||||
runTest("success", success)
|
||||
runTest("success previous epoch", success_previous_epoch)
|
||||
runTest("invalid attestation signature", invalid_attestation_signature)
|
||||
runTest("before inclusion delay", before_inclusion_delay)
|
||||
# https://github.com/ethereum/eth2.0-spec-tests/tree/v0.10.1/tests/minimal/phase0/operations/attestation/pyspec_tests
|
||||
# https://github.com/ethereum/eth2.0-spec-tests/tree/v0.10.1/tests/mainnet/phase0/operations/attestation/pyspec_tests
|
||||
runTest("after_epoch_slots", after_epoch_slots)
|
||||
runTest("bad source root", bad_source_root)
|
||||
runTest("before inclusion delay", before_inclusion_delay)
|
||||
runTest("empty aggregation bits", empty_aggregation_bits)
|
||||
runTest("future target epoch", future_target_epoch)
|
||||
runTest("invalid attestation signature", invalid_attestation_signature)
|
||||
runTest("invalid current source root", invalid_current_source_root)
|
||||
runTest("invalid index", invalid_index)
|
||||
runTest("mismatched target and slot", mismatched_target_and_slot)
|
||||
runTest("new source epoch", new_source_epoch)
|
||||
runTest("old source epoch", old_source_epoch)
|
||||
runTest("old target epoch", old_target_epoch)
|
||||
runTest("future target epoch", future_target_epoch)
|
||||
runTest("new source epoch", new_source_epoch)
|
||||
runTest("source root is target root", source_root_is_target_root)
|
||||
runTest("invalid current source root", invalid_current_source_root)
|
||||
runTest("bad source root", bad_source_root)
|
||||
runTest("empty aggregation bits", empty_aggregation_bits)
|
||||
runTest("too many aggregation bits", too_many_aggregation_bits)
|
||||
runTest("success", success)
|
||||
runTest("success multi-proposer index interations",
|
||||
success_multi_proposer_index_iterations)
|
||||
runTest("success previous epoch", success_previous_epoch)
|
||||
runTest("too few aggregation bits", too_few_aggregation_bits)
|
||||
runTest("too many aggregation bits", too_many_aggregation_bits)
|
||||
runTest("wrong index for committee signature",
|
||||
wrong_index_for_committee_signature)
|
||||
runTest("wrong index for slot", wrong_index_for_slot)
|
||||
|
|
|
@ -64,16 +64,18 @@ template runTest(identifier: untyped) =
|
|||
`testImpl _ voluntary_exit _ identifier`()
|
||||
|
||||
suite "Official - Operations - Voluntary exit " & preset():
|
||||
# https://github.com/ethereum/eth2.0-spec-tests/tree/v0.10.1/tests/minimal/phase0/operations/voluntary_exit/pyspec_tests
|
||||
# https://github.com/ethereum/eth2.0-spec-tests/tree/v0.10.1/tests/mainnet/phase0/operations/voluntary_exit/pyspec_tests
|
||||
runTest(success)
|
||||
|
||||
when false:
|
||||
# TODO not sure how this particularly could falsely succeed
|
||||
runTest(invalid_signature)
|
||||
|
||||
runTest(validator_invalid_validator_index)
|
||||
runTest(validator_already_exited)
|
||||
runTest(success_exit_queue)
|
||||
runTest(validator_exit_in_future)
|
||||
runTest(validator_invalid_validator_index)
|
||||
runTest(validator_not_active)
|
||||
runTest(validator_already_exited)
|
||||
runTest(default_exit_epoch_subsequent_exit)
|
||||
runTest(validator_not_active_long_enough)
|
||||
|
||||
runTest(validator_not_active)
|
||||
|
|
|
@ -47,6 +47,8 @@ template runTest(testName: string, identifier: untyped, num_slots: uint64): unty
|
|||
# ---------------------------------------------------------------
|
||||
|
||||
suite "Official - Sanity - Slots " & preset():
|
||||
# https://github.com/ethereum/eth2.0-spec-tests/tree/v0.10.1/tests/minimal/phase0/sanity/slots/pyspec_tests
|
||||
# https://github.com/ethereum/eth2.0-spec-tests/tree/v0.10.1/tests/mainnet/phase0/sanity/slots/pyspec_tests
|
||||
runTest("Advance 1 slot", slots_1, 1)
|
||||
runTest("Advance 2 slots", slots_2, 2)
|
||||
runTest("Advance an empty epoch", empty_epoch, SLOTS_PER_EPOCH)
|
||||
|
|
Loading…
Reference in New Issue