Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

refactor: move ef tests to own testing crate #2847

Merged
merged 5 commits into from
May 26, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 7 additions & 5 deletions .github/workflows/unit.yml
Original file line number Diff line number Diff line change
Expand Up @@ -57,28 +57,30 @@ jobs:
RUST_LOG: info,sync=error
steps:
- name: Checkout sources
uses: actions/checkout@v2
uses: actions/checkout@v3

- name: Checkout ethereum/tests
uses: actions/checkout@v2
uses: actions/checkout@v3
with:
repository: ethereum/tests
path: ethtests
path: testing/ef-tests/ethereum-tests
submodules: recursive
depth: 1

- name: Install toolchain
uses: actions-rs/toolchain@v1
with:
toolchain: stable
profile: minimal
override: true

- uses: Swatinem/rust-cache@v1
with:
cache-on-failure: true
- name: Install latest nextest release
uses: taiki-e/install-action@nextest

- name: Run Ethereum tests
run: cargo run --release -- test-chain ethtests/BlockchainTests/GeneralStateTests/
run: cargo nextest run --release -p ef-tests --features ef-tests

doc-test:
name: rustdoc
Expand Down
35 changes: 26 additions & 9 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,7 @@ members = [
"crates/tasks",
"crates/transaction-pool",
"crates/trie",
"testing/ef-tests"
]
default-members = ["bin/reth"]

Expand Down
6 changes: 1 addition & 5 deletions bin/reth/src/cli.rs
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ use crate::{
dirs::{LogsDir, PlatformPath},
merkle_debug, node, p2p,
runner::CliRunner,
stage, test_eth_chain, test_vectors,
stage, test_vectors,
version::{LONG_VERSION, SHORT_VERSION},
};
use clap::{ArgAction, Args, Parser, Subcommand};
Expand Down Expand Up @@ -35,7 +35,6 @@ pub fn run() -> eyre::Result<()> {
Commands::Stage(command) => runner.run_blocking_until_ctrl_c(command.execute()),
Commands::P2P(command) => runner.run_until_ctrl_c(command.execute()),
Commands::TestVectors(command) => runner.run_until_ctrl_c(command.execute()),
Commands::TestEthChain(command) => runner.run_until_ctrl_c(command.execute()),
Commands::Config(command) => runner.run_until_ctrl_c(command.execute()),
Commands::MerkleDebug(command) => runner.run_until_ctrl_c(command.execute()),
}
Expand All @@ -62,9 +61,6 @@ pub enum Commands {
/// P2P Debugging utilities
#[command(name = "p2p")]
P2P(p2p::Command),
/// Run Ethereum blockchain tests
#[command(name = "test-chain")]
TestEthChain(test_eth_chain::Command),
/// Generate Test Vectors
#[command(name = "test-vectors")]
TestVectors(test_vectors::Command),
Expand Down
1 change: 0 additions & 1 deletion bin/reth/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@ pub mod p2p;
pub mod prometheus_exporter;
pub mod runner;
pub mod stage;
pub mod test_eth_chain;
pub mod test_vectors;
pub mod utils;
pub mod version;
Expand Down
60 changes: 0 additions & 60 deletions bin/reth/src/test_eth_chain/mod.rs

This file was deleted.

Loading