minor fixes, doctoc
This commit is contained in:
parent
7c4b32a717
commit
dc2a2bd85a
18
README.md
18
README.md
|
@ -1,3 +1,21 @@
|
|||
<!-- START doctoc generated TOC please keep comment here to allow auto update -->
|
||||
<!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN doctoc TO UPDATE -->
|
||||
**Table of Contents** *generated with [DocToc](https://github.com/thlorenz/doctoc)*
|
||||
|
||||
- [Ethereum Proof-of-Stake Consensus Specifications](#ethereum-proof-of-stake-consensus-specifications)
|
||||
- [Specs](#specs)
|
||||
- [Stable Specifications](#stable-specifications)
|
||||
- [In-development Specifications](#in-development-specifications)
|
||||
- [Accompanying documents can be found in specs and include:](#accompanying-documents-can-be-found-in-specs-and-include)
|
||||
- [Additional specifications for client implementers](#additional-specifications-for-client-implementers)
|
||||
- [Design goals](#design-goals)
|
||||
- [Useful external resources](#useful-external-resources)
|
||||
- [For spec contributors](#for-spec-contributors)
|
||||
- [Online viewer of the latest release (latest `master` branch)](#online-viewer-of-the-latest-release-latest-master-branch)
|
||||
- [Consensus spec tests](#consensus-spec-tests)
|
||||
|
||||
<!-- END doctoc generated TOC please keep comment here to allow auto update -->
|
||||
|
||||
# Ethereum Proof-of-Stake Consensus Specifications
|
||||
|
||||
[![Join the chat at https://discord.gg/qGpsxSA](https://img.shields.io/badge/chat-on%20discord-blue.svg)](https://discord.gg/qGpsxSA)
|
||||
|
|
10
SECURITY.md
10
SECURITY.md
|
@ -1,3 +1,13 @@
|
|||
<!-- START doctoc generated TOC please keep comment here to allow auto update -->
|
||||
<!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN doctoc TO UPDATE -->
|
||||
**Table of Contents** *generated with [DocToc](https://github.com/thlorenz/doctoc)*
|
||||
|
||||
- [Security Policy](#security-policy)
|
||||
- [Supported Versions](#supported-versions)
|
||||
- [Reporting a Vulnerability](#reporting-a-vulnerability)
|
||||
|
||||
<!-- END doctoc generated TOC please keep comment here to allow auto update -->
|
||||
|
||||
# Security Policy
|
||||
|
||||
## Supported Versions
|
||||
|
|
|
@ -1,3 +1,13 @@
|
|||
<!-- START doctoc generated TOC please keep comment here to allow auto update -->
|
||||
<!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN doctoc TO UPDATE -->
|
||||
**Table of Contents** *generated with [DocToc](https://github.com/thlorenz/doctoc)*
|
||||
|
||||
- [Configurations](#configurations)
|
||||
- [Forking](#forking)
|
||||
- [Format](#format)
|
||||
|
||||
<!-- END doctoc generated TOC please keep comment here to allow auto update -->
|
||||
|
||||
# Configurations
|
||||
|
||||
This directory contains a set of configurations used for testing, testnets, and mainnet.
|
||||
|
|
|
@ -1,3 +1,11 @@
|
|||
<!-- START doctoc generated TOC please keep comment here to allow auto update -->
|
||||
<!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN doctoc TO UPDATE -->
|
||||
**Table of Contents** *generated with [DocToc](https://github.com/thlorenz/doctoc)*
|
||||
|
||||
- [Docker related information](#docker-related-information)
|
||||
|
||||
<!-- END doctoc generated TOC please keep comment here to allow auto update -->
|
||||
|
||||
## Docker related information
|
||||
|
||||
This dockerfile sets up the dependencies required to run consensus-spec tests. The docker image can be locally built with:
|
||||
|
|
|
@ -7,6 +7,24 @@
|
|||
<!-- START doctoc generated TOC please keep comment here to allow auto update -->
|
||||
<!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN doctoc TO UPDATE -->
|
||||
|
||||
- [Introduction](#introduction)
|
||||
- [Notation](#notation)
|
||||
- [Custom types](#custom-types)
|
||||
- [Constants](#constants)
|
||||
- [[CATEGORY OF CONSTANTS]](#category-of-constants)
|
||||
- [Preset](#preset)
|
||||
- [[CATEGORY OF PRESETS]](#category-of-presets)
|
||||
- [Configuration](#configuration)
|
||||
- [[CATEGORY OF CONFIGURATIONS]](#category-of-configurations)
|
||||
- [Containers](#containers)
|
||||
- [[CATEGORY OF CONTAINERS]](#category-of-containers)
|
||||
- [`CONTAINER_NAME`](#container_name)
|
||||
- [Helper functions](#helper-functions)
|
||||
- [[CATEGORY OF HELPERS]](#category-of-helpers)
|
||||
- [Epoch processing](#epoch-processing)
|
||||
- [Block processing](#block-processing)
|
||||
- [Testing](#testing)
|
||||
|
||||
<!-- END doctoc generated TOC please keep comment here to allow auto update -->
|
||||
<!-- /TOC -->
|
||||
|
||||
|
|
|
@ -1 +1,9 @@
|
|||
<!-- START doctoc generated TOC please keep comment here to allow auto update -->
|
||||
<!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN doctoc TO UPDATE -->
|
||||
**Table of Contents** *generated with [DocToc](https://github.com/thlorenz/doctoc)*
|
||||
|
||||
- [Light client specifications](#light-client-specifications)
|
||||
|
||||
<!-- END doctoc generated TOC please keep comment here to allow auto update -->
|
||||
|
||||
# Light client specifications
|
||||
|
|
|
@ -1,3 +1,13 @@
|
|||
<!-- START doctoc generated TOC please keep comment here to allow auto update -->
|
||||
<!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN doctoc TO UPDATE -->
|
||||
**Table of Contents** *generated with [DocToc](https://github.com/thlorenz/doctoc)*
|
||||
|
||||
- [Presets](#presets)
|
||||
- [Forking](#forking)
|
||||
- [Format](#format)
|
||||
|
||||
<!-- END doctoc generated TOC please keep comment here to allow auto update -->
|
||||
|
||||
# Presets
|
||||
|
||||
Presets are more extensive than runtime configurations, and generally only applicable during compile-time.
|
||||
|
|
|
@ -1,3 +1,15 @@
|
|||
<!-- START doctoc generated TOC please keep comment here to allow auto update -->
|
||||
<!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN doctoc TO UPDATE -->
|
||||
**Table of Contents** *generated with [DocToc](https://github.com/thlorenz/doctoc)*
|
||||
|
||||
- [Deposit Contract](#deposit-contract)
|
||||
- [History](#history)
|
||||
- [Compiling solidity deposit contract](#compiling-solidity-deposit-contract)
|
||||
- [Running web3 tests](#running-web3-tests)
|
||||
- [Running randomized `dapp` tests:](#running-randomized-dapp-tests)
|
||||
|
||||
<!-- END doctoc generated TOC please keep comment here to allow auto update -->
|
||||
|
||||
# Deposit Contract
|
||||
|
||||
## History
|
||||
|
|
|
@ -28,8 +28,7 @@
|
|||
- [`PendingBalanceDeposit`](#pendingbalancedeposit)
|
||||
- [`PendingPartialWithdrawal`](#pendingpartialwithdrawal)
|
||||
- [`ExecutionLayerWithdrawalRequest`](#executionlayerwithdrawalrequest)
|
||||
- [`Consolidation`](#consolidation)
|
||||
- [`SignedConsolidation`](#signedconsolidation)
|
||||
- [`ExecutionLayerConsolidationRequest`](#executionlayerconsolidationrequest)
|
||||
- [`PendingConsolidation`](#pendingconsolidation)
|
||||
- [Modified Containers](#modified-containers)
|
||||
- [`AttesterSlashing`](#attesterslashing)
|
||||
|
@ -94,8 +93,8 @@
|
|||
- [New `process_execution_layer_withdrawal_request`](#new-process_execution_layer_withdrawal_request)
|
||||
- [Deposit receipts](#deposit-receipts)
|
||||
- [New `process_deposit_receipt`](#new-process_deposit_receipt)
|
||||
- [Consolidations](#consolidations)
|
||||
- [New `process_consolidation`](#new-process_consolidation)
|
||||
- [Execution layer consolidation requests](#execution-layer-consolidation-requests)
|
||||
- [New `process_execution_layer_consolidation_request`](#new-process_execution_layer_consolidation_request)
|
||||
- [Testing](#testing)
|
||||
|
||||
<!-- END doctoc generated TOC please keep comment here to allow auto update -->
|
||||
|
@ -1286,10 +1285,10 @@ def process_deposit_receipt(state: BeaconState, deposit_receipt: DepositReceipt)
|
|||
|
||||
##### Execution layer consolidation requests
|
||||
|
||||
###### New `process_execution_layer_consolidation_requests`
|
||||
###### New `process_execution_layer_consolidation_request`
|
||||
|
||||
```python
|
||||
def process_execution_layer_consolidation_requests(
|
||||
def process_execution_layer_consolidation_request(
|
||||
state: BeaconState,
|
||||
execution_layer_consolidation_request: ExecutionLayerConsolidationRequest) -> None:
|
||||
# If the pending consolidations queue is full, consolidation requests are ignored
|
||||
|
|
|
@ -1,3 +1,20 @@
|
|||
<!-- START doctoc generated TOC please keep comment here to allow auto update -->
|
||||
<!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN doctoc TO UPDATE -->
|
||||
**Table of Contents** *generated with [DocToc](https://github.com/thlorenz/doctoc)*
|
||||
|
||||
- [Getting Started with Consensus Spec Tests](#getting-started-with-consensus-spec-tests)
|
||||
- [Getting Started](#getting-started)
|
||||
- [Creating the environment](#creating-the-environment)
|
||||
- [Running your first test](#running-your-first-test)
|
||||
- [The "Hello, World" of Consensus Spec Tests](#the-hello-world-of-consensus-spec-tests)
|
||||
- [New Tests](#new-tests)
|
||||
- [Tests Designed to Fail](#tests-designed-to-fail)
|
||||
- [Attestation Tests](#attestation-tests)
|
||||
- [Adding an Attestation Test](#adding-an-attestation-test)
|
||||
- [How are These Tests Used?](#how-are-these-tests-used)
|
||||
|
||||
<!-- END doctoc generated TOC please keep comment here to allow auto update -->
|
||||
|
||||
# Getting Started with Consensus Spec Tests
|
||||
|
||||
## Getting Started
|
||||
|
|
|
@ -1,3 +1,20 @@
|
|||
<!-- START doctoc generated TOC please keep comment here to allow auto update -->
|
||||
<!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN doctoc TO UPDATE -->
|
||||
**Table of Contents** *generated with [DocToc](https://github.com/thlorenz/doctoc)*
|
||||
|
||||
- [Executable Python Spec (PySpec)](#executable-python-spec-pyspec)
|
||||
- [Dev Install](#dev-install)
|
||||
- [Py-tests](#py-tests)
|
||||
- [How to run tests](#how-to-run-tests)
|
||||
- [Automated](#automated)
|
||||
- [Manual](#manual)
|
||||
- [How to view code coverage report](#how-to-view-code-coverage-report)
|
||||
- [Advanced](#advanced)
|
||||
- [Contributing](#contributing)
|
||||
- [License](#license)
|
||||
|
||||
<!-- END doctoc generated TOC please keep comment here to allow auto update -->
|
||||
|
||||
# Executable Python Spec (PySpec)
|
||||
|
||||
The executable Python spec is built from the consensus specifications,
|
||||
|
|
|
@ -1,3 +1,12 @@
|
|||
<!-- START doctoc generated TOC please keep comment here to allow auto update -->
|
||||
<!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN doctoc TO UPDATE -->
|
||||
**Table of Contents** *generated with [DocToc](https://github.com/thlorenz/doctoc)*
|
||||
|
||||
- [Consensus specs config util](#consensus-specs-config-util)
|
||||
- [Config usage:](#config-usage)
|
||||
|
||||
<!-- END doctoc generated TOC please keep comment here to allow auto update -->
|
||||
|
||||
# Consensus specs config util
|
||||
|
||||
For run-time configuration, see [Configs documentation](../../../../../configs/README.md).
|
||||
|
|
|
@ -1,3 +1,14 @@
|
|||
<!-- START doctoc generated TOC please keep comment here to allow auto update -->
|
||||
<!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN doctoc TO UPDATE -->
|
||||
**Table of Contents** *generated with [DocToc](https://github.com/thlorenz/doctoc)*
|
||||
|
||||
- [Consensus test generator helpers](#consensus-test-generator-helpers)
|
||||
- [`gen_base`](#gen_base)
|
||||
- [`gen_from_tests`](#gen_from_tests)
|
||||
- [Test-case parts](#test-case-parts)
|
||||
|
||||
<!-- END doctoc generated TOC please keep comment here to allow auto update -->
|
||||
|
||||
# Consensus test generator helpers
|
||||
|
||||
## `gen_base`
|
||||
|
|
|
@ -40,7 +40,7 @@ def test_basic_consolidation_in_current_consolidation_epoch(spec, state):
|
|||
spec, state, source_index, address=source_address
|
||||
)
|
||||
# Make consolidation with source address
|
||||
consolidation = spec.ExecutionLayerConsolidation(
|
||||
consolidation = spec.ExecutionLayerConsolidationRequest(
|
||||
source_address=source_address,
|
||||
source_pubkey=state.validators[source_index].pubkey,
|
||||
target_pubkey=state.validators[target_index].pubkey,
|
||||
|
@ -89,7 +89,7 @@ def test_basic_consolidation_in_new_consolidation_epoch(spec, state):
|
|||
spec, state, source_index, address=source_address
|
||||
)
|
||||
# Make consolidation with source address
|
||||
consolidation = spec.ExecutionLayerConsolidation(
|
||||
consolidation = spec.ExecutionLayerConsolidationRequest(
|
||||
source_address=source_address,
|
||||
source_pubkey=state.validators[source_index].pubkey,
|
||||
target_pubkey=state.validators[target_index].pubkey,
|
||||
|
@ -132,7 +132,7 @@ def test_basic_consolidation_with_preexisting_churn(spec, state):
|
|||
spec, state, source_index, address=source_address
|
||||
)
|
||||
# Make consolidation with source address
|
||||
consolidation = spec.ExecutionLayerConsolidation(
|
||||
consolidation = spec.ExecutionLayerConsolidationRequest(
|
||||
source_address=source_address,
|
||||
source_pubkey=state.validators[source_index].pubkey,
|
||||
target_pubkey=state.validators[target_index].pubkey,
|
||||
|
@ -179,7 +179,7 @@ def test_basic_consolidation_with_insufficient_preexisting_churn(spec, state):
|
|||
spec, state, source_index, address=source_address
|
||||
)
|
||||
# Make consolidation with source address
|
||||
consolidation = spec.ExecutionLayerConsolidation(
|
||||
consolidation = spec.ExecutionLayerConsolidationRequest(
|
||||
source_address=source_address,
|
||||
source_pubkey=state.validators[source_index].pubkey,
|
||||
target_pubkey=state.validators[target_index].pubkey,
|
||||
|
@ -230,7 +230,7 @@ def test_basic_consolidation_with_compounding_credentials(spec, state):
|
|||
spec, state, source_index, address=source_address
|
||||
)
|
||||
# Make consolidation with source address
|
||||
consolidation = spec.ExecutionLayerConsolidation(
|
||||
consolidation = spec.ExecutionLayerConsolidationRequest(
|
||||
source_address=source_address,
|
||||
source_pubkey=state.validators[source_index].pubkey,
|
||||
target_pubkey=state.validators[target_index].pubkey,
|
||||
|
@ -276,7 +276,7 @@ def test_consolidation_churn_limit_balance(spec, state):
|
|||
spec, state, source_index, address=source_address
|
||||
)
|
||||
# Make consolidation with source address
|
||||
consolidation = spec.ExecutionLayerConsolidation(
|
||||
consolidation = spec.ExecutionLayerConsolidationRequest(
|
||||
source_address=source_address,
|
||||
source_pubkey=state.validators[source_index].pubkey,
|
||||
target_pubkey=state.validators[target_index].pubkey,
|
||||
|
@ -324,7 +324,7 @@ def test_consolidation_balance_larger_than_churn_limit(spec, state):
|
|||
spec, state, source_index, address=source_address
|
||||
)
|
||||
# Make consolidation with source address
|
||||
consolidation = spec.ExecutionLayerConsolidation(
|
||||
consolidation = spec.ExecutionLayerConsolidationRequest(
|
||||
source_address=source_address,
|
||||
source_pubkey=state.validators[source_index].pubkey,
|
||||
target_pubkey=state.validators[target_index].pubkey,
|
||||
|
@ -371,7 +371,7 @@ def test_consolidation_balance_through_two_churn_epochs(spec, state):
|
|||
spec, state, source_index, address=source_address
|
||||
)
|
||||
# Make consolidation with source address
|
||||
consolidation = spec.ExecutionLayerConsolidation(
|
||||
consolidation = spec.ExecutionLayerConsolidationRequest(
|
||||
source_address=source_address,
|
||||
source_pubkey=state.validators[source_index].pubkey,
|
||||
target_pubkey=state.validators[target_index].pubkey,
|
||||
|
@ -417,7 +417,7 @@ def test_invalid_source_equals_target(spec, state):
|
|||
spec, state, source_index, address=source_address
|
||||
)
|
||||
# Make consolidation from source to source
|
||||
consolidation = spec.ExecutionLayerConsolidation(
|
||||
consolidation = spec.ExecutionLayerConsolidationRequest(
|
||||
source_address=source_address,
|
||||
source_pubkey=state.validators[source_index].pubkey,
|
||||
target_pubkey=state.validators[source_index].pubkey,
|
||||
|
@ -449,7 +449,7 @@ def test_invalid_exceed_pending_consolidations_limit(spec, state):
|
|||
set_eth1_withdrawal_credential_with_balance(
|
||||
spec, state, source_index, address=source_address
|
||||
)
|
||||
consolidation = spec.ExecutionLayerConsolidation(
|
||||
consolidation = spec.ExecutionLayerConsolidationRequest(
|
||||
source_address=source_address,
|
||||
source_pubkey=state.validators[source_index].pubkey,
|
||||
target_pubkey=state.validators[target_index].pubkey,
|
||||
|
@ -478,7 +478,7 @@ def test_invalid_not_enough_consolidation_churn_available(spec, state):
|
|||
set_eth1_withdrawal_credential_with_balance(
|
||||
spec, state, source_index, address=source_address
|
||||
)
|
||||
consolidation = spec.ExecutionLayerConsolidation(
|
||||
consolidation = spec.ExecutionLayerConsolidationRequest(
|
||||
source_address=source_address,
|
||||
source_pubkey=state.validators[source_index].pubkey,
|
||||
target_pubkey=state.validators[target_index].pubkey,
|
||||
|
@ -506,7 +506,7 @@ def test_invalid_exited_source(spec, state):
|
|||
set_eth1_withdrawal_credential_with_balance(
|
||||
spec, state, source_index, address=source_address
|
||||
)
|
||||
consolidation = spec.ExecutionLayerConsolidation(
|
||||
consolidation = spec.ExecutionLayerConsolidationRequest(
|
||||
source_address=source_address,
|
||||
source_pubkey=state.validators[source_index].pubkey,
|
||||
target_pubkey=state.validators[target_index].pubkey,
|
||||
|
@ -538,7 +538,7 @@ def test_invalid_exited_target(spec, state):
|
|||
set_eth1_withdrawal_credential_with_balance(
|
||||
spec, state, source_index, address=source_address
|
||||
)
|
||||
consolidation = spec.ExecutionLayerConsolidation(
|
||||
consolidation = spec.ExecutionLayerConsolidationRequest(
|
||||
source_address=source_address,
|
||||
source_pubkey=state.validators[source_index].pubkey,
|
||||
target_pubkey=state.validators[target_index].pubkey,
|
||||
|
@ -568,7 +568,7 @@ def test_invalid_inactive_source(spec, state):
|
|||
set_eth1_withdrawal_credential_with_balance(
|
||||
spec, state, source_index, address=source_address
|
||||
)
|
||||
consolidation = spec.ExecutionLayerConsolidation(
|
||||
consolidation = spec.ExecutionLayerConsolidationRequest(
|
||||
source_address=source_address,
|
||||
source_pubkey=state.validators[source_index].pubkey,
|
||||
target_pubkey=state.validators[target_index].pubkey,
|
||||
|
@ -600,7 +600,7 @@ def test_invalid_inactive_target(spec, state):
|
|||
set_eth1_withdrawal_credential_with_balance(
|
||||
spec, state, source_index, address=source_address
|
||||
)
|
||||
consolidation = spec.ExecutionLayerConsolidation(
|
||||
consolidation = spec.ExecutionLayerConsolidationRequest(
|
||||
source_address=source_address,
|
||||
source_pubkey=state.validators[source_index].pubkey,
|
||||
target_pubkey=state.validators[target_index].pubkey,
|
||||
|
@ -629,7 +629,7 @@ def test_invalid_no_source_execution_withdrawal_credential(spec, state):
|
|||
source_index = spec.get_active_validator_indices(state, current_epoch)[0]
|
||||
target_index = spec.get_active_validator_indices(state, current_epoch)[1]
|
||||
source_address = b"\x22" * 20
|
||||
consolidation = spec.ExecutionLayerConsolidation(
|
||||
consolidation = spec.ExecutionLayerConsolidationRequest(
|
||||
source_address=source_address,
|
||||
source_pubkey=state.validators[source_index].pubkey,
|
||||
target_pubkey=state.validators[target_index].pubkey,
|
||||
|
@ -657,7 +657,7 @@ def test_invalid_no_target_execution_withdrawal_credential(spec, state):
|
|||
set_eth1_withdrawal_credential_with_balance(
|
||||
spec, state, source_index, address=source_address
|
||||
)
|
||||
consolidation = spec.ExecutionLayerConsolidation(
|
||||
consolidation = spec.ExecutionLayerConsolidationRequest(
|
||||
source_address=source_address,
|
||||
source_pubkey=state.validators[source_index].pubkey,
|
||||
target_pubkey=state.validators[target_index].pubkey,
|
||||
|
@ -685,7 +685,7 @@ def test_invalid_incorrect_source_address(spec, state):
|
|||
spec, state, source_index, address=source_address
|
||||
)
|
||||
# Make consolidation with different source address
|
||||
consolidation = spec.ExecutionLayerConsolidation(
|
||||
consolidation = spec.ExecutionLayerConsolidationRequest(
|
||||
source_address=b"\x33" * 20,
|
||||
source_pubkey=state.validators[source_index].pubkey,
|
||||
target_pubkey=state.validators[target_index].pubkey,
|
||||
|
@ -715,7 +715,7 @@ def test_invalid_unknown_source_pubkey(spec, state):
|
|||
spec, state, source_index, address=source_address
|
||||
)
|
||||
# Make consolidation with different source pubkey
|
||||
consolidation = spec.ExecutionLayerConsolidation(
|
||||
consolidation = spec.ExecutionLayerConsolidationRequest(
|
||||
source_address=source_address,
|
||||
source_pubkey=b"\x00" * 48,
|
||||
target_pubkey=state.validators[target_index].pubkey,
|
||||
|
@ -744,7 +744,7 @@ def test_invalid_unknown_target_pubkey(spec, state):
|
|||
spec, state, source_index, address=source_address
|
||||
)
|
||||
# Make consolidation with different target pubkey
|
||||
consolidation = spec.ExecutionLayerConsolidation(
|
||||
consolidation = spec.ExecutionLayerConsolidationRequest(
|
||||
source_address=b"\x33" * 20,
|
||||
source_pubkey=state.validators[source_index].pubkey,
|
||||
target_pubkey=b"\x00" * 48,
|
||||
|
@ -782,7 +782,7 @@ def run_consolidation_processing(spec, state, consolidation, success=True):
|
|||
yield 'pre', state
|
||||
yield 'consolidation', consolidation
|
||||
|
||||
spec.process_execution_layer_consolidation(state, consolidation)
|
||||
spec.process_execution_layer_consolidation_request(state, consolidation)
|
||||
|
||||
yield 'post', state
|
||||
|
||||
|
|
|
@ -1,3 +1,32 @@
|
|||
<!-- START doctoc generated TOC please keep comment here to allow auto update -->
|
||||
<!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN doctoc TO UPDATE -->
|
||||
**Table of Contents** *generated with [DocToc](https://github.com/thlorenz/doctoc)*
|
||||
|
||||
- [General test format](#general-test-format)
|
||||
- [Table of contents](#table-of-contents)
|
||||
- [About](#about)
|
||||
- [Test-case formats](#test-case-formats)
|
||||
- [Glossary](#glossary)
|
||||
- [Test format philosophy](#test-format-philosophy)
|
||||
- [Config design](#config-design)
|
||||
- [Test completeness](#test-completeness)
|
||||
- [Test structure](#test-structure)
|
||||
- [`<config name>/`](#config-name)
|
||||
- [`<fork or phase name>/`](#fork-or-phase-name)
|
||||
- [`<test runner name>/`](#test-runner-name)
|
||||
- [`<test handler name>/`](#test-handler-name)
|
||||
- [`<test suite name>/`](#test-suite-name)
|
||||
- [`<test case>/`](#test-case)
|
||||
- [`<output part>`](#output-part)
|
||||
- [Common output formats](#common-output-formats)
|
||||
- [Special output parts](#special-output-parts)
|
||||
- [`meta.yaml`](#metayaml)
|
||||
- [`config.yaml`](#configyaml)
|
||||
- [Config sourcing](#config-sourcing)
|
||||
- [Note for implementers](#note-for-implementers)
|
||||
|
||||
<!-- END doctoc generated TOC please keep comment here to allow auto update -->
|
||||
|
||||
# General test format
|
||||
|
||||
This document defines the YAML format and structure used for consensus spec testing.
|
||||
|
|
|
@ -1,3 +1,11 @@
|
|||
<!-- START doctoc generated TOC please keep comment here to allow auto update -->
|
||||
<!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN doctoc TO UPDATE -->
|
||||
**Table of Contents** *generated with [DocToc](https://github.com/thlorenz/doctoc)*
|
||||
|
||||
- [BLS tests](#bls-tests)
|
||||
|
||||
<!-- END doctoc generated TOC please keep comment here to allow auto update -->
|
||||
|
||||
# BLS tests
|
||||
|
||||
A test type for BLS. Primarily geared towards verifying the *integration* of any BLS library.
|
||||
|
|
|
@ -1,3 +1,13 @@
|
|||
<!-- START doctoc generated TOC please keep comment here to allow auto update -->
|
||||
<!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN doctoc TO UPDATE -->
|
||||
**Table of Contents** *generated with [DocToc](https://github.com/thlorenz/doctoc)*
|
||||
|
||||
- [Test format: BLS signature aggregation](#test-format-bls-signature-aggregation)
|
||||
- [Test case format](#test-case-format)
|
||||
- [Condition](#condition)
|
||||
|
||||
<!-- END doctoc generated TOC please keep comment here to allow auto update -->
|
||||
|
||||
# Test format: BLS signature aggregation
|
||||
|
||||
A BLS signature aggregation combines a series of signatures into a single signature.
|
||||
|
|
|
@ -1,3 +1,13 @@
|
|||
<!-- START doctoc generated TOC please keep comment here to allow auto update -->
|
||||
<!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN doctoc TO UPDATE -->
|
||||
**Table of Contents** *generated with [DocToc](https://github.com/thlorenz/doctoc)*
|
||||
|
||||
- [Test format: BLS sign message](#test-format-bls-sign-message)
|
||||
- [Test case format](#test-case-format)
|
||||
- [Condition](#condition)
|
||||
|
||||
<!-- END doctoc generated TOC please keep comment here to allow auto update -->
|
||||
|
||||
# Test format: BLS sign message
|
||||
|
||||
Verify the signature against the given pubkeys and one messages.
|
||||
|
|
|
@ -1,3 +1,13 @@
|
|||
<!-- START doctoc generated TOC please keep comment here to allow auto update -->
|
||||
<!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN doctoc TO UPDATE -->
|
||||
**Table of Contents** *generated with [DocToc](https://github.com/thlorenz/doctoc)*
|
||||
|
||||
- [Test format: Ethereum-customized BLS pubkey aggregation](#test-format-ethereum-customized-bls-pubkey-aggregation)
|
||||
- [Test case format](#test-case-format)
|
||||
- [Condition](#condition)
|
||||
|
||||
<!-- END doctoc generated TOC please keep comment here to allow auto update -->
|
||||
|
||||
# Test format: Ethereum-customized BLS pubkey aggregation
|
||||
|
||||
A BLS pubkey aggregation combines a series of pubkeys into a single pubkey.
|
||||
|
|
|
@ -1,3 +1,13 @@
|
|||
<!-- START doctoc generated TOC please keep comment here to allow auto update -->
|
||||
<!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN doctoc TO UPDATE -->
|
||||
**Table of Contents** *generated with [DocToc](https://github.com/thlorenz/doctoc)*
|
||||
|
||||
- [Test format: Ethereum-customized BLS fast aggregate verify](#test-format-ethereum-customized-bls-fast-aggregate-verify)
|
||||
- [Test case format](#test-case-format)
|
||||
- [Condition](#condition)
|
||||
|
||||
<!-- END doctoc generated TOC please keep comment here to allow auto update -->
|
||||
|
||||
# Test format: Ethereum-customized BLS fast aggregate verify
|
||||
|
||||
Verify the signature against the given pubkeys and one message.
|
||||
|
|
|
@ -1,3 +1,13 @@
|
|||
<!-- START doctoc generated TOC please keep comment here to allow auto update -->
|
||||
<!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN doctoc TO UPDATE -->
|
||||
**Table of Contents** *generated with [DocToc](https://github.com/thlorenz/doctoc)*
|
||||
|
||||
- [Test format: BLS fast aggregate verify](#test-format-bls-fast-aggregate-verify)
|
||||
- [Test case format](#test-case-format)
|
||||
- [Condition](#condition)
|
||||
|
||||
<!-- END doctoc generated TOC please keep comment here to allow auto update -->
|
||||
|
||||
# Test format: BLS fast aggregate verify
|
||||
|
||||
Verify the signature against the given pubkeys and one message.
|
||||
|
|
|
@ -1,3 +1,13 @@
|
|||
<!-- START doctoc generated TOC please keep comment here to allow auto update -->
|
||||
<!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN doctoc TO UPDATE -->
|
||||
**Table of Contents** *generated with [DocToc](https://github.com/thlorenz/doctoc)*
|
||||
|
||||
- [Test format: BLS sign message](#test-format-bls-sign-message)
|
||||
- [Test case format](#test-case-format)
|
||||
- [Condition](#condition)
|
||||
|
||||
<!-- END doctoc generated TOC please keep comment here to allow auto update -->
|
||||
|
||||
# Test format: BLS sign message
|
||||
|
||||
Message signing with BLS should produce a signature.
|
||||
|
|
|
@ -1,3 +1,12 @@
|
|||
<!-- START doctoc generated TOC please keep comment here to allow auto update -->
|
||||
<!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN doctoc TO UPDATE -->
|
||||
**Table of Contents** *generated with [DocToc](https://github.com/thlorenz/doctoc)*
|
||||
|
||||
- [Test format: BLS sign message](#test-format-bls-sign-message)
|
||||
- [Test case format](#test-case-format)
|
||||
|
||||
<!-- END doctoc generated TOC please keep comment here to allow auto update -->
|
||||
|
||||
# Test format: BLS sign message
|
||||
|
||||
Verify the signature against the given one pubkey and one message.
|
||||
|
|
|
@ -1,3 +1,16 @@
|
|||
<!-- START doctoc generated TOC please keep comment here to allow auto update -->
|
||||
<!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN doctoc TO UPDATE -->
|
||||
**Table of Contents** *generated with [DocToc](https://github.com/thlorenz/doctoc)*
|
||||
|
||||
- [Epoch processing tests](#epoch-processing-tests)
|
||||
- [Test case format](#test-case-format)
|
||||
- [`meta.yaml`](#metayaml)
|
||||
- [`pre.ssz_snappy`](#pressz_snappy)
|
||||
- [`post.ssz_snappy`](#postssz_snappy)
|
||||
- [Condition](#condition)
|
||||
|
||||
<!-- END doctoc generated TOC please keep comment here to allow auto update -->
|
||||
|
||||
# Epoch processing tests
|
||||
|
||||
The different epoch sub-transitions are tested individually with test handlers.
|
||||
|
|
|
@ -1,3 +1,17 @@
|
|||
<!-- START doctoc generated TOC please keep comment here to allow auto update -->
|
||||
<!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN doctoc TO UPDATE -->
|
||||
**Table of Contents** *generated with [DocToc](https://github.com/thlorenz/doctoc)*
|
||||
|
||||
- [Finality tests](#finality-tests)
|
||||
- [Test case format](#test-case-format)
|
||||
- [`meta.yaml`](#metayaml)
|
||||
- [`pre.ssz_snappy`](#pressz_snappy)
|
||||
- [`blocks_<index>.yaml`](#blocks_indexyaml)
|
||||
- [`post.ssz_snappy`](#postssz_snappy)
|
||||
- [Condition](#condition)
|
||||
|
||||
<!-- END doctoc generated TOC please keep comment here to allow auto update -->
|
||||
|
||||
# Finality tests
|
||||
|
||||
The aim of the tests for the finality rules.
|
||||
|
|
|
@ -1,3 +1,18 @@
|
|||
<!-- START doctoc generated TOC please keep comment here to allow auto update -->
|
||||
<!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN doctoc TO UPDATE -->
|
||||
**Table of Contents** *generated with [DocToc](https://github.com/thlorenz/doctoc)*
|
||||
|
||||
- [Forks](#forks)
|
||||
- [Test case format](#test-case-format)
|
||||
- [`meta.yaml`](#metayaml)
|
||||
- [Fork strings](#fork-strings)
|
||||
- [`pre.ssz_snappy`](#pressz_snappy)
|
||||
- [`post.ssz_snappy`](#postssz_snappy)
|
||||
- [Processing](#processing)
|
||||
- [Condition](#condition)
|
||||
|
||||
<!-- END doctoc generated TOC please keep comment here to allow auto update -->
|
||||
|
||||
# Forks
|
||||
|
||||
The aim of the fork tests is to ensure that a pre-fork state can be transformed
|
||||
|
|
|
@ -1,3 +1,11 @@
|
|||
<!-- START doctoc generated TOC please keep comment here to allow auto update -->
|
||||
<!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN doctoc TO UPDATE -->
|
||||
**Table of Contents** *generated with [DocToc](https://github.com/thlorenz/doctoc)*
|
||||
|
||||
- [Genesis tests](#genesis-tests)
|
||||
|
||||
<!-- END doctoc generated TOC please keep comment here to allow auto update -->
|
||||
|
||||
# Genesis tests
|
||||
|
||||
The aim of the genesis tests is to provide a baseline to test genesis-state initialization and test
|
||||
|
|
|
@ -1,3 +1,19 @@
|
|||
<!-- START doctoc generated TOC please keep comment here to allow auto update -->
|
||||
<!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN doctoc TO UPDATE -->
|
||||
**Table of Contents** *generated with [DocToc](https://github.com/thlorenz/doctoc)*
|
||||
|
||||
- [Genesis creation testing](#genesis-creation-testing)
|
||||
- [Test case format](#test-case-format)
|
||||
- [`eth1.yaml`](#eth1yaml)
|
||||
- [`meta.yaml`](#metayaml)
|
||||
- [`deposits_<index>.ssz_snappy`](#deposits_indexssz_snappy)
|
||||
- [`execution_payload_header.ssz_snappy`](#execution_payload_headerssz_snappy)
|
||||
- [`state.ssz_snappy`](#statessz_snappy)
|
||||
- [Processing](#processing)
|
||||
- [Condition](#condition)
|
||||
|
||||
<!-- END doctoc generated TOC please keep comment here to allow auto update -->
|
||||
|
||||
# Genesis creation testing
|
||||
|
||||
Tests the initialization of a genesis state based on Eth1 data.
|
||||
|
|
|
@ -1,3 +1,17 @@
|
|||
<!-- START doctoc generated TOC please keep comment here to allow auto update -->
|
||||
<!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN doctoc TO UPDATE -->
|
||||
**Table of Contents** *generated with [DocToc](https://github.com/thlorenz/doctoc)*
|
||||
|
||||
- [Genesis validity testing](#genesis-validity-testing)
|
||||
- [Test case format](#test-case-format)
|
||||
- [`meta.yaml`](#metayaml)
|
||||
- [`genesis.ssz_snappy`](#genesisssz_snappy)
|
||||
- [`is_valid.yaml`](#is_validyaml)
|
||||
- [Processing](#processing)
|
||||
- [Condition](#condition)
|
||||
|
||||
<!-- END doctoc generated TOC please keep comment here to allow auto update -->
|
||||
|
||||
# Genesis validity testing
|
||||
|
||||
Tests if a genesis state is valid, i.e. if it counts as trigger to launch.
|
||||
|
|
|
@ -1,3 +1,11 @@
|
|||
<!-- START doctoc generated TOC please keep comment here to allow auto update -->
|
||||
<!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN doctoc TO UPDATE -->
|
||||
**Table of Contents** *generated with [DocToc](https://github.com/thlorenz/doctoc)*
|
||||
|
||||
- [KZG tests](#kzg-tests)
|
||||
|
||||
<!-- END doctoc generated TOC please keep comment here to allow auto update -->
|
||||
|
||||
# KZG tests
|
||||
|
||||
A test type for KZG libraries. Tests all the public interfaces that a KZG library required to implement EIP-4844 needs to provide, as defined in `polynomial-commitments.md`.
|
||||
|
|
|
@ -1,3 +1,13 @@
|
|||
<!-- START doctoc generated TOC please keep comment here to allow auto update -->
|
||||
<!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN doctoc TO UPDATE -->
|
||||
**Table of Contents** *generated with [DocToc](https://github.com/thlorenz/doctoc)*
|
||||
|
||||
- [Test format: Blob to KZG commitment](#test-format-blob-to-kzg-commitment)
|
||||
- [Test case format](#test-case-format)
|
||||
- [Condition](#condition)
|
||||
|
||||
<!-- END doctoc generated TOC please keep comment here to allow auto update -->
|
||||
|
||||
# Test format: Blob to KZG commitment
|
||||
|
||||
Compute the KZG commitment for a given `blob`.
|
||||
|
|
|
@ -1,3 +1,13 @@
|
|||
<!-- START doctoc generated TOC please keep comment here to allow auto update -->
|
||||
<!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN doctoc TO UPDATE -->
|
||||
**Table of Contents** *generated with [DocToc](https://github.com/thlorenz/doctoc)*
|
||||
|
||||
- [Test format: Compute blob KZG proof](#test-format-compute-blob-kzg-proof)
|
||||
- [Test case format](#test-case-format)
|
||||
- [Condition](#condition)
|
||||
|
||||
<!-- END doctoc generated TOC please keep comment here to allow auto update -->
|
||||
|
||||
# Test format: Compute blob KZG proof
|
||||
|
||||
Compute the blob KZG proof for a given `blob`, that helps with quickly verifying that the KZG commitment for the blob is correct.
|
||||
|
|
|
@ -1,3 +1,13 @@
|
|||
<!-- START doctoc generated TOC please keep comment here to allow auto update -->
|
||||
<!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN doctoc TO UPDATE -->
|
||||
**Table of Contents** *generated with [DocToc](https://github.com/thlorenz/doctoc)*
|
||||
|
||||
- [Test format: Compute KZG proof](#test-format-compute-kzg-proof)
|
||||
- [Test case format](#test-case-format)
|
||||
- [Condition](#condition)
|
||||
|
||||
<!-- END doctoc generated TOC please keep comment here to allow auto update -->
|
||||
|
||||
# Test format: Compute KZG proof
|
||||
|
||||
Compute the KZG proof for a given `blob` and an evaluation point `z`.
|
||||
|
|
|
@ -1,3 +1,13 @@
|
|||
<!-- START doctoc generated TOC please keep comment here to allow auto update -->
|
||||
<!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN doctoc TO UPDATE -->
|
||||
**Table of Contents** *generated with [DocToc](https://github.com/thlorenz/doctoc)*
|
||||
|
||||
- [Test format: Verify blob KZG proof](#test-format-verify-blob-kzg-proof)
|
||||
- [Test case format](#test-case-format)
|
||||
- [Condition](#condition)
|
||||
|
||||
<!-- END doctoc generated TOC please keep comment here to allow auto update -->
|
||||
|
||||
# Test format: Verify blob KZG proof
|
||||
|
||||
Use the blob KZG proof to verify that the KZG commitment for a given `blob` is correct
|
||||
|
|
|
@ -1,3 +1,13 @@
|
|||
<!-- START doctoc generated TOC please keep comment here to allow auto update -->
|
||||
<!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN doctoc TO UPDATE -->
|
||||
**Table of Contents** *generated with [DocToc](https://github.com/thlorenz/doctoc)*
|
||||
|
||||
- [Test format: Verify blob KZG proof batch](#test-format-verify-blob-kzg-proof-batch)
|
||||
- [Test case format](#test-case-format)
|
||||
- [Condition](#condition)
|
||||
|
||||
<!-- END doctoc generated TOC please keep comment here to allow auto update -->
|
||||
|
||||
# Test format: Verify blob KZG proof batch
|
||||
|
||||
Use the blob KZG proofs to verify that the KZG commitments for given `blobs` are correct
|
||||
|
|
|
@ -1,3 +1,13 @@
|
|||
<!-- START doctoc generated TOC please keep comment here to allow auto update -->
|
||||
<!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN doctoc TO UPDATE -->
|
||||
**Table of Contents** *generated with [DocToc](https://github.com/thlorenz/doctoc)*
|
||||
|
||||
- [Test format: Verify KZG proof](#test-format-verify-kzg-proof)
|
||||
- [Test case format](#test-case-format)
|
||||
- [Condition](#condition)
|
||||
|
||||
<!-- END doctoc generated TOC please keep comment here to allow auto update -->
|
||||
|
||||
# Test format: Verify KZG proof
|
||||
|
||||
Verify the KZG proof for a given `blob` and an evaluation point `z` that claims to result in a value of `y`.
|
||||
|
|
|
@ -1,3 +1,11 @@
|
|||
<!-- START doctoc generated TOC please keep comment here to allow auto update -->
|
||||
<!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN doctoc TO UPDATE -->
|
||||
**Table of Contents** *generated with [DocToc](https://github.com/thlorenz/doctoc)*
|
||||
|
||||
- [Light client sync protocol tests](#light-client-sync-protocol-tests)
|
||||
|
||||
<!-- END doctoc generated TOC please keep comment here to allow auto update -->
|
||||
|
||||
# Light client sync protocol tests
|
||||
|
||||
This series of tests provides reference test vectors for the light client sync protocol spec.
|
||||
|
|
|
@ -1,3 +1,15 @@
|
|||
<!-- START doctoc generated TOC please keep comment here to allow auto update -->
|
||||
<!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN doctoc TO UPDATE -->
|
||||
**Table of Contents** *generated with [DocToc](https://github.com/thlorenz/doctoc)*
|
||||
|
||||
- [Single leaf merkle proof tests](#single-leaf-merkle-proof-tests)
|
||||
- [Test case format](#test-case-format)
|
||||
- [`object.ssz_snappy`](#objectssz_snappy)
|
||||
- [`proof.yaml`](#proofyaml)
|
||||
- [Condition](#condition)
|
||||
|
||||
<!-- END doctoc generated TOC please keep comment here to allow auto update -->
|
||||
|
||||
# Single leaf merkle proof tests
|
||||
|
||||
This series of tests provides reference test vectors for validating correct
|
||||
|
|
|
@ -1,3 +1,20 @@
|
|||
<!-- START doctoc generated TOC please keep comment here to allow auto update -->
|
||||
<!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN doctoc TO UPDATE -->
|
||||
**Table of Contents** *generated with [DocToc](https://github.com/thlorenz/doctoc)*
|
||||
|
||||
- [Light client sync tests](#light-client-sync-tests)
|
||||
- [Test case format](#test-case-format)
|
||||
- [`meta.yaml`](#metayaml)
|
||||
- [`bootstrap.ssz_snappy`](#bootstrapssz_snappy)
|
||||
- [`steps.yaml`](#stepsyaml)
|
||||
- [Checks to run after each step](#checks-to-run-after-each-step)
|
||||
- [`force_update` execution step](#force_update-execution-step)
|
||||
- [`process_update` execution step](#process_update-execution-step)
|
||||
- [`upgrade_store`](#upgrade_store)
|
||||
- [Condition](#condition)
|
||||
|
||||
<!-- END doctoc generated TOC please keep comment here to allow auto update -->
|
||||
|
||||
# Light client sync tests
|
||||
|
||||
This series of tests provides reference test vectors for validating that a light client implementing the sync protocol can sync to the latest block header.
|
||||
|
|
|
@ -1,3 +1,15 @@
|
|||
<!-- START doctoc generated TOC please keep comment here to allow auto update -->
|
||||
<!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN doctoc TO UPDATE -->
|
||||
**Table of Contents** *generated with [DocToc](https://github.com/thlorenz/doctoc)*
|
||||
|
||||
- [`LightClientUpdate` ranking tests](#lightclientupdate-ranking-tests)
|
||||
- [Test case format](#test-case-format)
|
||||
- [`meta.yaml`](#metayaml)
|
||||
- [`updates_<index>.ssz_snappy`](#updates_indexssz_snappy)
|
||||
- [Condition](#condition)
|
||||
|
||||
<!-- END doctoc generated TOC please keep comment here to allow auto update -->
|
||||
|
||||
# `LightClientUpdate` ranking tests
|
||||
|
||||
This series of tests provides reference test vectors for validating that `LightClientUpdate` instances are ranked in a canonical order.
|
||||
|
|
|
@ -1,3 +1,11 @@
|
|||
<!-- START doctoc generated TOC please keep comment here to allow auto update -->
|
||||
<!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN doctoc TO UPDATE -->
|
||||
**Table of Contents** *generated with [DocToc](https://github.com/thlorenz/doctoc)*
|
||||
|
||||
- [Merkle proof tests](#merkle-proof-tests)
|
||||
|
||||
<!-- END doctoc generated TOC please keep comment here to allow auto update -->
|
||||
|
||||
# Merkle proof tests
|
||||
|
||||
Handlers:
|
||||
|
|
|
@ -1,3 +1,17 @@
|
|||
<!-- START doctoc generated TOC please keep comment here to allow auto update -->
|
||||
<!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN doctoc TO UPDATE -->
|
||||
**Table of Contents** *generated with [DocToc](https://github.com/thlorenz/doctoc)*
|
||||
|
||||
- [Operations tests](#operations-tests)
|
||||
- [Test case format](#test-case-format)
|
||||
- [`meta.yaml`](#metayaml)
|
||||
- [`pre.ssz_snappy`](#pressz_snappy)
|
||||
- [`<input-name>.ssz_snappy`](#input-namessz_snappy)
|
||||
- [`post.ssz_snappy`](#postssz_snappy)
|
||||
- [Condition](#condition)
|
||||
|
||||
<!-- END doctoc generated TOC please keep comment here to allow auto update -->
|
||||
|
||||
# Operations tests
|
||||
|
||||
The different kinds of operations ("transactions") are tested individually with test handlers.
|
||||
|
|
|
@ -1,3 +1,12 @@
|
|||
<!-- START doctoc generated TOC please keep comment here to allow auto update -->
|
||||
<!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN doctoc TO UPDATE -->
|
||||
**Table of Contents** *generated with [DocToc](https://github.com/thlorenz/doctoc)*
|
||||
|
||||
- [Random tests](#random-tests)
|
||||
- [Test case format](#test-case-format)
|
||||
|
||||
<!-- END doctoc generated TOC please keep comment here to allow auto update -->
|
||||
|
||||
# Random tests
|
||||
|
||||
The random tests are generated with various randomized states and blocks.
|
||||
|
|
|
@ -1,3 +1,20 @@
|
|||
<!-- START doctoc generated TOC please keep comment here to allow auto update -->
|
||||
<!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN doctoc TO UPDATE -->
|
||||
**Table of Contents** *generated with [DocToc](https://github.com/thlorenz/doctoc)*
|
||||
|
||||
- [Rewards tests](#rewards-tests)
|
||||
- [Test case format](#test-case-format)
|
||||
- [`meta.yaml`](#metayaml)
|
||||
- [`pre.ssz_snappy`](#pressz_snappy)
|
||||
- [`source_deltas.ssz_snappy`](#source_deltasssz_snappy)
|
||||
- [`target_deltas.ssz_snappy`](#target_deltasssz_snappy)
|
||||
- [`head_deltas.ssz_snappy`](#head_deltasssz_snappy)
|
||||
- [`inclusion_delay_deltas.ssz_snappy`](#inclusion_delay_deltasssz_snappy)
|
||||
- [`inactivity_penalty_deltas.ssz_snappy`](#inactivity_penalty_deltasssz_snappy)
|
||||
- [Condition](#condition)
|
||||
|
||||
<!-- END doctoc generated TOC please keep comment here to allow auto update -->
|
||||
|
||||
# Rewards tests
|
||||
|
||||
All rewards deltas sub-functions are tested for each test case.
|
||||
|
|
|
@ -1,3 +1,11 @@
|
|||
<!-- START doctoc generated TOC please keep comment here to allow auto update -->
|
||||
<!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN doctoc TO UPDATE -->
|
||||
**Table of Contents** *generated with [DocToc](https://github.com/thlorenz/doctoc)*
|
||||
|
||||
- [Sanity tests](#sanity-tests)
|
||||
|
||||
<!-- END doctoc generated TOC please keep comment here to allow auto update -->
|
||||
|
||||
# Sanity tests
|
||||
|
||||
The aim of the sanity tests is to set a base-line on what really needs to pass, i.e. the essentials.
|
||||
|
|
|
@ -1,3 +1,17 @@
|
|||
<!-- START doctoc generated TOC please keep comment here to allow auto update -->
|
||||
<!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN doctoc TO UPDATE -->
|
||||
**Table of Contents** *generated with [DocToc](https://github.com/thlorenz/doctoc)*
|
||||
|
||||
- [Sanity blocks testing](#sanity-blocks-testing)
|
||||
- [Test case format](#test-case-format)
|
||||
- [`meta.yaml`](#metayaml)
|
||||
- [`pre.ssz_snappy`](#pressz_snappy)
|
||||
- [`blocks_<index>.ssz_snappy`](#blocks_indexssz_snappy)
|
||||
- [`post.ssz_snappy`](#postssz_snappy)
|
||||
- [Condition](#condition)
|
||||
|
||||
<!-- END doctoc generated TOC please keep comment here to allow auto update -->
|
||||
|
||||
# Sanity blocks testing
|
||||
|
||||
Sanity tests to cover a series of one or more blocks being processed, aiming to cover common changes.
|
||||
|
|
|
@ -1,3 +1,18 @@
|
|||
<!-- START doctoc generated TOC please keep comment here to allow auto update -->
|
||||
<!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN doctoc TO UPDATE -->
|
||||
**Table of Contents** *generated with [DocToc](https://github.com/thlorenz/doctoc)*
|
||||
|
||||
- [Sanity slots testing](#sanity-slots-testing)
|
||||
- [Test case format](#test-case-format)
|
||||
- [`meta.yaml`](#metayaml)
|
||||
- [`pre.ssz_snappy`](#pressz_snappy)
|
||||
- [`slots.yaml`](#slotsyaml)
|
||||
- [`post.ssz_snappy`](#postssz_snappy)
|
||||
- [Processing](#processing)
|
||||
- [Condition](#condition)
|
||||
|
||||
<!-- END doctoc generated TOC please keep comment here to allow auto update -->
|
||||
|
||||
# Sanity slots testing
|
||||
|
||||
Sanity tests to cover a series of one or more empty-slot transitions being processed, aiming to cover common changes.
|
||||
|
|
|
@ -1,3 +1,14 @@
|
|||
<!-- START doctoc generated TOC please keep comment here to allow auto update -->
|
||||
<!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN doctoc TO UPDATE -->
|
||||
**Table of Contents** *generated with [DocToc](https://github.com/thlorenz/doctoc)*
|
||||
|
||||
- [Test format: shuffling](#test-format-shuffling)
|
||||
- [Test case format](#test-case-format)
|
||||
- [`mapping.yaml`](#mappingyaml)
|
||||
- [Condition](#condition)
|
||||
|
||||
<!-- END doctoc generated TOC please keep comment here to allow auto update -->
|
||||
|
||||
# Test format: shuffling
|
||||
|
||||
The runner of the Shuffling test type has only one handler: `core`.
|
||||
|
|
|
@ -1,3 +1,26 @@
|
|||
<!-- START doctoc generated TOC please keep comment here to allow auto update -->
|
||||
<!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN doctoc TO UPDATE -->
|
||||
**Table of Contents** *generated with [DocToc](https://github.com/thlorenz/doctoc)*
|
||||
|
||||
- [SSZ, generic tests](#ssz-generic-tests)
|
||||
- [Format](#format)
|
||||
- [`valid`](#valid)
|
||||
- [`meta.yaml`](#metayaml)
|
||||
- [`serialized.ssz_snappy`](#serializedssz_snappy)
|
||||
- [`value.yaml`](#valueyaml)
|
||||
- [Conditions](#conditions)
|
||||
- [`invalid`](#invalid)
|
||||
- [Condition](#condition)
|
||||
- [Type declarations](#type-declarations)
|
||||
- [`basic_vector`](#basic_vector)
|
||||
- [`bitlist`](#bitlist)
|
||||
- [`bitvector`](#bitvector)
|
||||
- [`boolean`](#boolean)
|
||||
- [`uints`](#uints)
|
||||
- [`containers`](#containers)
|
||||
|
||||
<!-- END doctoc generated TOC please keep comment here to allow auto update -->
|
||||
|
||||
# SSZ, generic tests
|
||||
|
||||
This set of test-suites provides general testing for SSZ:
|
||||
|
|
|
@ -1,3 +1,11 @@
|
|||
<!-- START doctoc generated TOC please keep comment here to allow auto update -->
|
||||
<!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN doctoc TO UPDATE -->
|
||||
**Table of Contents** *generated with [DocToc](https://github.com/thlorenz/doctoc)*
|
||||
|
||||
- [SSZ, static tests](#ssz-static-tests)
|
||||
|
||||
<!-- END doctoc generated TOC please keep comment here to allow auto update -->
|
||||
|
||||
# SSZ, static tests
|
||||
|
||||
This set of test-suites provides static testing for SSZ:
|
||||
|
|
|
@ -1,3 +1,17 @@
|
|||
<!-- START doctoc generated TOC please keep comment here to allow auto update -->
|
||||
<!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN doctoc TO UPDATE -->
|
||||
**Table of Contents** *generated with [DocToc](https://github.com/thlorenz/doctoc)*
|
||||
|
||||
- [Test format: SSZ static types](#test-format-ssz-static-types)
|
||||
- [Test case format](#test-case-format)
|
||||
- [`roots.yaml`](#rootsyaml)
|
||||
- [`serialized.ssz_snappy`](#serializedssz_snappy)
|
||||
- [`value.yaml`](#valueyaml)
|
||||
- [Condition](#condition)
|
||||
- [References](#references)
|
||||
|
||||
<!-- END doctoc generated TOC please keep comment here to allow auto update -->
|
||||
|
||||
# Test format: SSZ static types
|
||||
|
||||
The goal of this type is to provide clients with a solid reference for how the known SSZ objects should be encoded.
|
||||
|
|
|
@ -1,3 +1,11 @@
|
|||
<!-- START doctoc generated TOC please keep comment here to allow auto update -->
|
||||
<!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN doctoc TO UPDATE -->
|
||||
**Table of Contents** *generated with [DocToc](https://github.com/thlorenz/doctoc)*
|
||||
|
||||
- [Sync tests](#sync-tests)
|
||||
|
||||
<!-- END doctoc generated TOC please keep comment here to allow auto update -->
|
||||
|
||||
# Sync tests
|
||||
|
||||
It re-uses the [fork choice test format](../fork_choice/README.md) to apply the test script.
|
||||
|
|
|
@ -1,3 +1,17 @@
|
|||
<!-- START doctoc generated TOC please keep comment here to allow auto update -->
|
||||
<!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN doctoc TO UPDATE -->
|
||||
**Table of Contents** *generated with [DocToc](https://github.com/thlorenz/doctoc)*
|
||||
|
||||
- [Transition testing](#transition-testing)
|
||||
- [Test case format](#test-case-format)
|
||||
- [`meta.yaml`](#metayaml)
|
||||
- [`pre.ssz_snappy`](#pressz_snappy)
|
||||
- [`blocks_<index>.ssz_snappy`](#blocks_indexssz_snappy)
|
||||
- [`post.ssz_snappy`](#postssz_snappy)
|
||||
- [Condition](#condition)
|
||||
|
||||
<!-- END doctoc generated TOC please keep comment here to allow auto update -->
|
||||
|
||||
# Transition testing
|
||||
|
||||
Transition tests to cover processing the chain across a fork boundary.
|
||||
|
|
|
@ -14,7 +14,6 @@ An automated nightly tests release system, with a config filter applied, is bein
|
|||
<!-- START doctoc generated TOC please keep comment here to allow auto update -->
|
||||
<!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN doctoc TO UPDATE -->
|
||||
|
||||
|
||||
- [How to run generators](#how-to-run-generators)
|
||||
- [Cleaning](#cleaning)
|
||||
- [Running all test generators](#running-all-test-generators)
|
||||
|
|
|
@ -1,3 +1,12 @@
|
|||
<!-- START doctoc generated TOC please keep comment here to allow auto update -->
|
||||
<!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN doctoc TO UPDATE -->
|
||||
**Table of Contents** *generated with [DocToc](https://github.com/thlorenz/doctoc)*
|
||||
|
||||
- [BLS Test Generator](#bls-test-generator)
|
||||
- [Resources](#resources)
|
||||
|
||||
<!-- END doctoc generated TOC please keep comment here to allow auto update -->
|
||||
|
||||
# BLS Test Generator
|
||||
|
||||
The [BLS Signature APIs](../../../specs/phase0/beacon-chain.md#bls-signatures)
|
||||
|
|
|
@ -1,3 +1,11 @@
|
|||
<!-- START doctoc generated TOC please keep comment here to allow auto update -->
|
||||
<!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN doctoc TO UPDATE -->
|
||||
**Table of Contents** *generated with [DocToc](https://github.com/thlorenz/doctoc)*
|
||||
|
||||
- [Epoch processing](#epoch-processing)
|
||||
|
||||
<!-- END doctoc generated TOC please keep comment here to allow auto update -->
|
||||
|
||||
# Epoch processing
|
||||
|
||||
Epoch processing covers the sub-transitions during an epoch change.
|
||||
|
|
|
@ -1,3 +1,11 @@
|
|||
<!-- START doctoc generated TOC please keep comment here to allow auto update -->
|
||||
<!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN doctoc TO UPDATE -->
|
||||
**Table of Contents** *generated with [DocToc](https://github.com/thlorenz/doctoc)*
|
||||
|
||||
- [Finality tests](#finality-tests)
|
||||
|
||||
<!-- END doctoc generated TOC please keep comment here to allow auto update -->
|
||||
|
||||
# Finality tests
|
||||
|
||||
Finality tests cover regular state-transitions in a common block-list format to test finality rules.
|
||||
|
|
|
@ -1,3 +1,11 @@
|
|||
<!-- START doctoc generated TOC please keep comment here to allow auto update -->
|
||||
<!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN doctoc TO UPDATE -->
|
||||
**Table of Contents** *generated with [DocToc](https://github.com/thlorenz/doctoc)*
|
||||
|
||||
- [Fork choice tests](#fork-choice-tests)
|
||||
|
||||
<!-- END doctoc generated TOC please keep comment here to allow auto update -->
|
||||
|
||||
# Fork choice tests
|
||||
|
||||
Fork choice tests cover the different forking cases with fork choice helper functions.
|
||||
|
|
|
@ -1,3 +1,11 @@
|
|||
<!-- START doctoc generated TOC please keep comment here to allow auto update -->
|
||||
<!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN doctoc TO UPDATE -->
|
||||
**Table of Contents** *generated with [DocToc](https://github.com/thlorenz/doctoc)*
|
||||
|
||||
- [Genesis test generator](#genesis-test-generator)
|
||||
|
||||
<!-- END doctoc generated TOC please keep comment here to allow auto update -->
|
||||
|
||||
# Genesis test generator
|
||||
|
||||
Genesis tests cover the initialization and validity-based launch trigger for the Beacon Chain genesis state.
|
||||
|
|
|
@ -1,3 +1,11 @@
|
|||
<!-- START doctoc generated TOC please keep comment here to allow auto update -->
|
||||
<!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN doctoc TO UPDATE -->
|
||||
**Table of Contents** *generated with [DocToc](https://github.com/thlorenz/doctoc)*
|
||||
|
||||
- [KZG 4844 Test Generator](#kzg-4844-test-generator)
|
||||
|
||||
<!-- END doctoc generated TOC please keep comment here to allow auto update -->
|
||||
|
||||
# KZG 4844 Test Generator
|
||||
|
||||
These tests are specific to the KZG API required for implementing EIP-4844
|
|
@ -1,3 +1,11 @@
|
|||
<!-- START doctoc generated TOC please keep comment here to allow auto update -->
|
||||
<!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN doctoc TO UPDATE -->
|
||||
**Table of Contents** *generated with [DocToc](https://github.com/thlorenz/doctoc)*
|
||||
|
||||
- [Light client tests](#light-client-tests)
|
||||
|
||||
<!-- END doctoc generated TOC please keep comment here to allow auto update -->
|
||||
|
||||
# Light client tests
|
||||
|
||||
The purpose of this test-generator is to provide test-vectors for validating the correct implementation of the light client sync protocol.
|
||||
|
|
|
@ -1,3 +1,11 @@
|
|||
<!-- START doctoc generated TOC please keep comment here to allow auto update -->
|
||||
<!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN doctoc TO UPDATE -->
|
||||
**Table of Contents** *generated with [DocToc](https://github.com/thlorenz/doctoc)*
|
||||
|
||||
- [Merkle proof tests](#merkle-proof-tests)
|
||||
|
||||
<!-- END doctoc generated TOC please keep comment here to allow auto update -->
|
||||
|
||||
# Merkle proof tests
|
||||
|
||||
The purpose of this test-generator is to provide test-vectors for validating the correct implementation of the Merkle proof verification.
|
||||
|
|
|
@ -1,3 +1,11 @@
|
|||
<!-- START doctoc generated TOC please keep comment here to allow auto update -->
|
||||
<!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN doctoc TO UPDATE -->
|
||||
**Table of Contents** *generated with [DocToc](https://github.com/thlorenz/doctoc)*
|
||||
|
||||
- [Operations](#operations)
|
||||
|
||||
<!-- END doctoc generated TOC please keep comment here to allow auto update -->
|
||||
|
||||
# Operations
|
||||
|
||||
Operations (or "transactions" in previous spec iterations),
|
||||
|
|
|
@ -1,3 +1,14 @@
|
|||
<!-- START doctoc generated TOC please keep comment here to allow auto update -->
|
||||
<!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN doctoc TO UPDATE -->
|
||||
**Table of Contents** *generated with [DocToc](https://github.com/thlorenz/doctoc)*
|
||||
|
||||
- [Randomized tests](#randomized-tests)
|
||||
- [To generate test sources](#to-generate-test-sources)
|
||||
- [To run tests](#to-run-tests)
|
||||
- [To generate spec tests (from the generated files)](#to-generate-spec-tests-from-the-generated-files)
|
||||
|
||||
<!-- END doctoc generated TOC please keep comment here to allow auto update -->
|
||||
|
||||
# Randomized tests
|
||||
|
||||
Randomized tests in the format of `sanity` blocks tests, with randomized operations.
|
||||
|
|
|
@ -1,3 +1,11 @@
|
|||
<!-- START doctoc generated TOC please keep comment here to allow auto update -->
|
||||
<!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN doctoc TO UPDATE -->
|
||||
**Table of Contents** *generated with [DocToc](https://github.com/thlorenz/doctoc)*
|
||||
|
||||
- [Rewards](#rewards)
|
||||
|
||||
<!-- END doctoc generated TOC please keep comment here to allow auto update -->
|
||||
|
||||
# Rewards
|
||||
|
||||
Rewards covers the sub-functions of `process_rewards_and_penalties` for granular testing of components of the rewards function.
|
||||
|
|
|
@ -1,3 +1,11 @@
|
|||
<!-- START doctoc generated TOC please keep comment here to allow auto update -->
|
||||
<!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN doctoc TO UPDATE -->
|
||||
**Table of Contents** *generated with [DocToc](https://github.com/thlorenz/doctoc)*
|
||||
|
||||
- [Sanity tests](#sanity-tests)
|
||||
|
||||
<!-- END doctoc generated TOC please keep comment here to allow auto update -->
|
||||
|
||||
# Sanity tests
|
||||
|
||||
Sanity tests cover regular state-transitions in a common block-list format, to ensure the basics work.
|
||||
|
|
|
@ -1,3 +1,11 @@
|
|||
<!-- START doctoc generated TOC please keep comment here to allow auto update -->
|
||||
<!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN doctoc TO UPDATE -->
|
||||
**Table of Contents** *generated with [DocToc](https://github.com/thlorenz/doctoc)*
|
||||
|
||||
- [Shuffling Tests](#shuffling-tests)
|
||||
|
||||
<!-- END doctoc generated TOC please keep comment here to allow auto update -->
|
||||
|
||||
# Shuffling Tests
|
||||
|
||||
Tests for the swap-or-not shuffling in the beacon chain.
|
||||
|
|
|
@ -1,3 +1,11 @@
|
|||
<!-- START doctoc generated TOC please keep comment here to allow auto update -->
|
||||
<!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN doctoc TO UPDATE -->
|
||||
**Table of Contents** *generated with [DocToc](https://github.com/thlorenz/doctoc)*
|
||||
|
||||
- [SSZ-static](#ssz-static)
|
||||
|
||||
<!-- END doctoc generated TOC please keep comment here to allow auto update -->
|
||||
|
||||
# SSZ-static
|
||||
|
||||
The purpose of this test-generator is to provide test-vectors for the most important applications of SSZ:
|
||||
|
|
Loading…
Reference in New Issue