Skip to content

Conversation

jonastheis
Copy link
Contributor

@jonastheis jonastheis commented Sep 11, 2025

  • Adds improvements to the Docker testing framework
  • some more misc improvements and fixes
  • Adds an extensive test case as described below
/// Tests cross-client block propagation and synchronization between heterogeneous nodes.
///
/// This integration test validates that blocks can be successfully propagated between
/// different Ethereum client implementations (l2geth and rollup-node) in various
/// network topologies. The test exercises:
///
/// 1. **Isolated Network Segments**: Initially runs l2geth nodes in isolation, verifying they can
///    produce and sync blocks independently
///    - Topology: `l2geth_follower -> l2geth_sequencer`
///    - l2geth_sequencer produces blocks, l2geth_follower syncs
///    - Rollup nodes remain disconnected at block 0
///
/// 2. **Cross-Client Synchronization**: Connects rollup nodes to the l2geth network, ensuring they
///    can catch up to the current chain state
///    - Topology: `[rn_follower, rn_sequencer, l2geth_follower] -> l2geth_sequencer`
///    - All nodes connect to l2geth_sequencer as the single source of truth
///    - Rollup nodes sync from block 0 to current height
///
/// 3. **Sequencer Handoff**: Transitions block production from l2geth to rollup-node, testing that
///    all nodes stay synchronized during the transition
///    - Topology remains: `[rn_follower, rn_sequencer, l2geth_follower] -> l2geth_sequencer`
///    - Block production switches from l2geth_sequencer to rn_sequencer
///    - All nodes receive new blocks from rn_sequencer via l2geth_sequencer relay
///
/// 4. **Network Partition Recovery**: Disconnects l2geth nodes, continues production on rollup
///    nodes, then reconnects to verify successful resynchronization
///    - Initial partition: `rn_follower -> rn_sequencer` (isolated rollup network)
///    - l2geth nodes disconnected, fall behind in block height
///    - Reconnection topology: `[l2geth_follower, l2geth_sequencer] -> rn_sequencer`
///    - l2geth nodes catch up by syncing from rn_sequencer
///
/// 5. **Bidirectional Compatibility**: Returns block production to l2geth after rollup nodes have
///    extended the chain, ensuring backward compatibility
///    - Final topology: `[rn_follower, l2geth_follower, l2geth_sequencer] -> rn_sequencer`
///    - Block production returns to l2geth_sequencer
///    - Validates that l2geth can continue the chain after rollup node blocks
///
/// The test validates that both client implementations maintain consensus despite
/// network topology changes, sequencer transitions, and temporary network partitions.
/// Each topology change tests different aspects of peer discovery, block gossip,
/// and chain synchronization across heterogeneous client implementations.

Closes #274

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[E2E Test] Migrate sequencer from L2geth to reth
2 participants