Skip to content
Draft
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: 3 additions & 9 deletions .circleci/continue/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -1824,10 +1824,6 @@ jobs:

op-acceptance-tests:
parameters:
gate:
description: The gate to run. Reads package list from op-acceptance-tests/gates/<gate>.txt. If empty, runs all tests.
type: string
default: ""
l2_cl_kind:
description: "L2 consensus layer client (op-node or kona-node)"
type: string
Expand Down Expand Up @@ -1881,7 +1877,7 @@ jobs:
working_directory: op-acceptance-tests
no_output_timeout: <<parameters.no_output_timeout>>
command: |
LOG_LEVEL=info just acceptance-test "<<parameters.gate>>"
LOG_LEVEL=info just acceptance-test
- run:
name: Print results (summary)
working_directory: op-acceptance-tests
Expand Down Expand Up @@ -2778,10 +2774,9 @@ workflows:
- cannon-prestate
- rust-binaries-for-sysgo
- go-binaries-for-sysgo
# IN-MEMORY (base gate) - op-node/op-reth
# IN-MEMORY - op-node/op-reth
- op-acceptance-tests:
name: memory-all-opn-op-reth
gate: "base"
l2_el_kind: op-reth
no_output_timeout: 120m
context:
Expand All @@ -2793,10 +2788,9 @@ workflows:
- cannon-prestate
- rust-binaries-for-sysgo
- go-binaries-for-sysgo
# IN-MEMORY (base gate) - kona/op-reth
# IN-MEMORY - kona/op-reth
- op-acceptance-tests:
name: memory-all-kona-op-reth
gate: "base"
l2_cl_kind: kona-node
l2_el_kind: op-reth
no_output_timeout: 120m
Expand Down
12 changes: 0 additions & 12 deletions op-acceptance-tests/gates/base.txt

This file was deleted.

33 changes: 5 additions & 28 deletions op-acceptance-tests/justfile
Original file line number Diff line number Diff line change
Expand Up @@ -4,16 +4,11 @@ REPO_ROOT := `realpath ..` # path to the root of the optimism monorepo
default:
@just acceptance-test

# Run acceptance tests, optionally filtered by a gate (reads packages from gates/<gate>.txt)
acceptance-test gate="":
# Run acceptance tests
acceptance-test:
#!/usr/bin/env bash
set -euo pipefail
GATE="{{gate}}"
if [[ -n "$GATE" ]]; then
echo -e "DEVNET: in-memory, GATE: $GATE\n"
else
echo -e "DEVNET: in-memory, MODE: all tests\n"
fi
echo -e "DEVNET: in-memory\n"

# Build dependencies for in-process mode if not in CI.
# In CI jobs already take care of this, so we skip it.
Expand Down Expand Up @@ -66,7 +61,7 @@ acceptance-test gate="":

JOBS="${ACCEPTANCE_TEST_JOBS:-$DEFAULT_JOBS}"
TEST_PARALLEL="${ACCEPTANCE_TEST_PARALLEL:-$DEFAULT_TEST_PARALLEL}"
TEST_TIMEOUT="${ACCEPTANCE_TEST_TIMEOUT:-2h}"
TEST_TIMEOUT="${ACCEPTANCE_TEST_TIMEOUT:-30m}"
echo "CPU COUNT: $CPU_COUNT"
echo "PACKAGE JOBS: $JOBS"
echo "TEST PARALLELISM: $TEST_PARALLEL"
Expand All @@ -92,25 +87,7 @@ acceptance-test gate="":
grep -RIn "MarkFlaky(" ./op-acceptance-tests/tests > "$FLAKY_REPORT" || true
fi

# Determine which packages to test
if [[ -n "$GATE" ]]; then
GATE_FILE="{{REPO_ROOT}}/op-acceptance-tests/gates/${GATE}.txt"
if [[ ! -f "$GATE_FILE" ]]; then
echo "error: gate file not found: $GATE_FILE" >&2
exit 1
fi
# Read non-empty, non-comment lines from the gate file
TEST_PACKAGES=()
while IFS= read -r line; do
line="${line%%#*}" # strip comments
line="${line// /}" # strip whitespace
[[ -z "$line" ]] && continue
TEST_PACKAGES+=("$line")
done < "$GATE_FILE"
echo "Gate '$GATE': ${#TEST_PACKAGES[@]} packages"
else
TEST_PACKAGES=("./op-acceptance-tests/tests/...")
fi
TEST_PACKAGES=("./op-acceptance-tests/tests/...")

set +e
LOG_LEVEL="${LOG_LEVEL}" {{REPO_ROOT}}/ops/scripts/gotestsum-split.sh \
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ import (
"github.com/ethereum-optimism/optimism/op-devstack/devtest"
"github.com/ethereum-optimism/optimism/op-devstack/dsl"
"github.com/ethereum-optimism/optimism/op-devstack/presets"
"github.com/ethereum-optimism/optimism/op-devstack/sysgo"
"github.com/ethereum-optimism/optimism/op-service/testlog"
"github.com/ethereum/go-ethereum/log"
"github.com/stretchr/testify/require"
Expand All @@ -23,6 +24,12 @@ type conductorWithInfo struct {
// TestConductorLeadershipTransfer checks if the leadership transfer works correctly on the conductors
func TestConductorLeadershipTransfer(gt *testing.T) {
t := devtest.ParallelT(gt)
// Example error with kona-node:
//
// --- FAIL: TestConductorLeadershipTransfer (63.04s)
// panic: interface conversion: sysgo.L2CLNode is *sysgo.KonaNode, not *sysgo.OpNode [recovered]
// panic: interface conversion: sysgo.L2CLNode is *sysgo.KonaNode, not *sysgo.OpNode
sysgo.SkipOnKonaNode(t, "not supported")
logger := testlog.Logger(t, log.LevelInfo).With("Test", "TestConductorLeadershipTransfer")

sys := presets.NewMinimalWithConductors(t)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ import (
"github.com/ethereum-optimism/optimism/op-acceptance-tests/tests/depreqres/common"
"github.com/ethereum-optimism/optimism/op-devstack/devtest"
"github.com/ethereum-optimism/optimism/op-devstack/presets"
"github.com/ethereum-optimism/optimism/op-devstack/sysgo"
"github.com/ethereum-optimism/optimism/op-node/rollup/sync"
"github.com/ethereum-optimism/optimism/op-service/eth"
"github.com/ethereum-optimism/optimism/op-supervisor/supervisor/types"
Expand All @@ -19,6 +20,15 @@ import (
// the corresponding block, and therefore does not serve it.
func TestCLELDivergence(gt *testing.T) {
t := devtest.ParallelT(gt)
// Example error with kona-node:
//
// assertions.go:387: ERROR[03-31|10:19:50.846]
// assertions.go:387: Error Trace: /Users/josh/repos/optimism/op-acceptance-tests/tests/depreqres/reqressyncdisabled/divergence/divergence_test.go:34
// assertions.go:387: Error: Not equal:
// assertions.go:387: expected: 0x1
// assertions.go:387: actual : 0x0
// assertions.go:387: Test: TestCLELDivergence
sysgo.SkipOnKonaNode(t, "not supported")
sys := presets.NewSingleChainMultiNodeWithoutP2PWithoutCheck(t, common.ReqRespSyncDisabledOpts(sync.ELSync)...)
require := t.Require()
l := t.Logger()
Expand Down
7 changes: 5 additions & 2 deletions op-acceptance-tests/tests/ecotone/fees_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,11 @@ import (
)

func TestFees(gt *testing.T) {
t := devtest.ParallelT(gt)
sys := presets.NewMinimal(t, presets.WithDeployerOptions(sysgo.WithEcotoneAtGenesis))
presets.RunCLAndELMatrix(devtest.ParallelT(gt), testFees)
}

func testFees(t devtest.T, opt presets.Option) {
sys := presets.NewMinimal(t, presets.WithDeployerOptions(sysgo.WithEcotoneAtGenesis), opt)

alice := sys.FunderL2.NewFundedEOA(eth.OneTenthEther)
bob := sys.Wallet.NewEOA(sys.L2EL)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ import (

"github.com/ethereum-optimism/optimism/op-devstack/devtest"
"github.com/ethereum-optimism/optimism/op-devstack/presets"
"github.com/ethereum-optimism/optimism/op-devstack/sysgo"
"github.com/ethereum-optimism/optimism/op-service/log/logfilter"
"github.com/ethereum-optimism/optimism/op-service/logmods"
"github.com/ethereum/go-ethereum/log"
Expand All @@ -22,6 +23,23 @@ const maxExpectedFlashblocks = 20
// TestFlashblocksStream checks we can connect to the flashblocks stream across multiple CL backends.
func TestFlashblocksStream(gt *testing.T) {
t := devtest.ParallelT(gt)
// Example error with kona-node:
//
// assertions.go:387: ERROR[03-30|22:44:52.250]
// assertions.go:387: Error Trace: /home/circleci/project/op-devstack/sysgo/l2_cl_kona.go:99
// assertions.go:387: /home/circleci/project/op-devstack/sysgo/mixed_runtime.go:456
// assertions.go:387: /home/circleci/project/op-devstack/sysgo/singlechain_build.go:182
// assertions.go:387: /home/circleci/project/op-devstack/sysgo/singlechain_build.go:276
// assertions.go:387: /home/circleci/project/op-devstack/sysgo/singlechain_flashblocks.go:36
// assertions.go:387: /home/circleci/project/op-devstack/sysgo/singlechain_runtime.go:105
// assertions.go:387: /home/circleci/project/op-devstack/sysgo/singlechain_flashblocks.go:53
// assertions.go:387: /home/circleci/project/op-devstack/presets/flashblocks.go:43
// assertions.go:387: /home/circleci/project/op-acceptance-tests/tests/flashblocks/flashblocks_stream_test.go:26
// assertions.go:387: Error: Received unexpected error:
// assertions.go:387: context deadline exceeded
// assertions.go:387: Test: TestFlashblocksStream
// assertions.go:387: Messages: need user RPC
sysgo.SkipOnKonaNode(t, "not supported (fail to get user rpc)")
logger := t.Logger()
sys := presets.NewSingleChainWithFlashblocks(t)
filterHandler, ok := logmods.FindHandler[logfilter.FilterHandler](logger.Handler())
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ import (

"github.com/ethereum-optimism/optimism/op-devstack/devtest"
"github.com/ethereum-optimism/optimism/op-devstack/presets"
"github.com/ethereum-optimism/optimism/op-devstack/sysgo"
"github.com/ethereum-optimism/optimism/op-service/eth"
"github.com/ethereum-optimism/optimism/op-service/txplan"
"github.com/stretchr/testify/require"
Expand All @@ -32,6 +33,23 @@ type timedMessage struct {
// - That Flashblock's time in nanoseconds must be before the approximated transaction confirmation time recorded previously.
func TestFlashblocksTransfer(gt *testing.T) {
t := devtest.ParallelT(gt)
// Example error with kona-node:
//
// assertions.go:387: ERROR[03-30|22:44:52.250]
// assertions.go:387: Error Trace: /op-devstack/sysgo/l2_cl_kona.go:99
// assertions.go:387: /op-devstack/sysgo/mixed_runtime.go:456
// assertions.go:387: /op-devstack/sysgo/singlechain_build.go:182
// assertions.go:387: /op-devstack/sysgo/singlechain_build.go:276
// assertions.go:387: /op-devstack/sysgo/singlechain_flashblocks.go:36
// assertions.go:387: /op-devstack/sysgo/singlechain_runtime.go:105
// assertions.go:387: /op-devstack/sysgo/singlechain_flashblocks.go:53
// assertions.go:387: /op-devstack/presets/flashblocks.go:43
// assertions.go:387: /op-acceptance-tests/tests/flashblocks/flashblocks_transfer_test.go:38
// assertions.go:387: Error: Received unexpected error:
// assertions.go:387: context deadline exceeded
// assertions.go:387: Test: TestFlashblocksTransfer
// assertions.go:387: Messages: need user RPC
sysgo.SkipOnKonaNode(t, "not supported (fail to get user rpc)")
logger := t.Logger()
tracer := t.Tracer()
ctx := t.Ctx()
Expand Down
15 changes: 15 additions & 0 deletions op-acceptance-tests/tests/proofs/cannon/step_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,12 +5,14 @@ import (

"github.com/ethereum-optimism/optimism/op-devstack/devtest"
"github.com/ethereum-optimism/optimism/op-devstack/dsl/proofs"
"github.com/ethereum-optimism/optimism/op-devstack/sysgo"
"github.com/ethereum-optimism/optimism/op-service/eth"
"github.com/ethereum-optimism/optimism/op-supervisor/supervisor/types"
)

func TestExecuteStep_Cannon(gt *testing.T) {
t := devtest.ParallelT(gt)
sysgo.SkipOnOpReth(t, "not supported (timeout)")
sys := newSystem(t)

l1User := sys.FunderL1.NewFundedEOA(eth.ThousandEther)
Expand All @@ -28,6 +30,19 @@ func TestExecuteStep_Cannon(gt *testing.T) {

func TestExecuteStep_CannonKona(gt *testing.T) {
t := devtest.ParallelT(gt)
// Example error with kona-node:
//
// assertions.go:387: ERROR[03-31|10:33:38.442]
// assertions.go:387: Error Trace: /optimism/op-devstack/dsl/proofs/game_helper.go:263
// assertions.go:387: /optimism/op-devstack/dsl/proofs/game_helper.go:196
// assertions.go:387: /optimism/op-devstack/dsl/proofs/fault_dispute_game.go:124
// assertions.go:387: /optimism/op-acceptance-tests/tests/proofs/cannon/step_test.go:40
// assertions.go:387: /.local/share/mise/installs/go/1.24.13/src/runtime/asm_arm64.s:1223
// assertions.go:387: Error: Received unexpected error:
// assertions.go:387: failed to get safe head at L1 block 0xe926b953777546729b2607011590354a6a42dc35e36b7ea68c9dd4b470261541:6: not found
// assertions.go:387: Test: TestExecuteStep_CannonKona
// assertions.go:387: Messages: Failed to get honest root claim
sysgo.SkipOnKonaNode(t, "not supported")
sys := newSystem(t)

l1User := sys.FunderL1.NewFundedEOA(eth.ThousandEther)
Expand Down
12 changes: 12 additions & 0 deletions op-acceptance-tests/tests/safeheaddb_clsync/safeheaddb_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,18 @@ import (

func TestPreserveDatabaseOnCLResync(gt *testing.T) {
t := devtest.ParallelT(gt)
// Example error with op-reth:
//
// assertions.go:387: ERROR[03-31|09:40:50.281]
// assertions.go:387: Error Trace: /optimism/op-devstack/sysgo/l2_el_p2p_util.go:61
// assertions.go:387: /optimism/op-devstack/dsl/l2_el.go:281
// assertions.go:387: /optimism/op-acceptance-tests/tests/safeheaddb_clsync/safeheaddb_test.go:42
// assertions.go:387: Error: Received unexpected error:
// assertions.go:387: context deadline exceeded
// assertions.go:387: Test: TestPreserveDatabaseOnCLResync
// assertions.go:387: Messages: The peer was not connected
// assertions.go:387:
sysgo.SkipOnOpReth(t, "not supported (peering issue)")
sys := presets.NewSingleChainMultiNode(t,
presets.WithGlobalL2CLOption(sysgo.L2CLOptionFn(func(p devtest.T, _ sysgo.ComponentTarget, cfg *sysgo.L2CLConfig) {
cfg.SequencerSyncMode = sync.CLSync
Expand Down
22 changes: 22 additions & 0 deletions op-acceptance-tests/tests/safeheaddb_elsync/safeheaddb_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,18 @@ func newSingleChainMultiNodeELSync(t devtest.T) *presets.SingleChainMultiNode {

func TestTruncateDatabaseOnELResync(gt *testing.T) {
t := devtest.ParallelT(gt)
// Example error with op-reth:
//
// assertions.go:387: ERROR[03-31|09:41:28.788]
// assertions.go:387: Error Trace: /optimism/op-devstack/sysgo/l2_el_p2p_util.go:61
// assertions.go:387: /optimism/op-devstack/dsl/l2_el.go:281
// assertions.go:387: /optimism/op-acceptance-tests/tests/safeheaddb_elsync/safeheaddb_test.go:44
// assertions.go:387: Error: Received unexpected error:
// assertions.go:387: dial tcp 127.0.0.1:55994: i/o timeout
// assertions.go:387: Test: TestTruncateDatabaseOnELResync
// assertions.go:387: Messages: The peer was not connected
// assertions.go:387:
sysgo.SkipOnOpReth(t, "not supported (peering issue)")
sys := newSingleChainMultiNodeELSync(t)

dsl.CheckAll(t,
Expand Down Expand Up @@ -51,6 +63,16 @@ func TestTruncateDatabaseOnELResync(gt *testing.T) {

func TestNotTruncateDatabaseOnRestartWithExistingDatabase(gt *testing.T) {
t := devtest.ParallelT(gt)
// Example error with kona-node:
//
// assertions.go:387: ERROR[03-31|10:35:59.154]
// assertions.go:387: Error Trace: /Users/josh/repos/optimism/op-devstack/dsl/safedb.go:22
// assertions.go:387: /Users/josh/repos/optimism/op-devstack/dsl/l2_cl.go:432
// assertions.go:387: /Users/josh/repos/optimism/op-acceptance-tests/tests/safeheaddb_elsync/safeheaddb_test.go:74
// assertions.go:387: Error: Expected value not to be nil.
// assertions.go:387: Test: TestNotTruncateDatabaseOnRestartWithExistingDatabase
// assertions.go:387: Messages: no safe head data available at L1 block 4
sysgo.SkipOnKonaNode(t, "not supported")
sys := newSingleChainMultiNodeELSync(t)

dsl.CheckAll(t,
Expand Down
13 changes: 13 additions & 0 deletions op-acceptance-tests/tests/sync/clsync/gap_clp2p/sync_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,13 +4,26 @@ import (
"testing"

"github.com/ethereum-optimism/optimism/op-devstack/devtest"
"github.com/ethereum-optimism/optimism/op-devstack/sysgo"
"github.com/ethereum-optimism/optimism/op-service/eth"
"github.com/ethereum-optimism/optimism/op-supervisor/supervisor/types"
)

// TestSyncAfterInitialELSync tests that blocks received out of order would be processed in order when running in CL sync mode. Note that this is not going to happen when running in EL sync mode, which relies on healthy ELP2P, something that is disabled in this test.
func TestSyncAfterInitialELSync(gt *testing.T) {
t := devtest.ParallelT(gt)
// Example error with kona-node:
//
// assertions.go:387: ERROR[03-31|10:38:08.992]
// "\n\tError Trace:\t/optimism/op-devstack/dsl/l2_el.go:192\n\t
// \t\t\t\t/optimism/op-acceptance-tests/tests/sync/clsync/gap_clp2p/sync_test.go:46
// \n\tError:
// \tReceived unexpected error:\n\t
// \toperation failed permanently after 2 attempts: expected head for label=latest to advance to target=5,
// but got current=2
// \tTest: \tTestSyncAfterInitialELSync\n"

sysgo.SkipOnKonaNode(t, "not supported")
sys := newGapCLP2PSystem(t)
require := t.Require()

Expand Down
11 changes: 11 additions & 0 deletions op-acceptance-tests/tests/sync/elsync/gap_clp2p/sync_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ import (
"testing"

"github.com/ethereum-optimism/optimism/op-devstack/devtest"
"github.com/ethereum-optimism/optimism/op-devstack/sysgo"
"github.com/ethereum-optimism/optimism/op-service/eth"
"github.com/ethereum-optimism/optimism/op-supervisor/supervisor/types"
)
Expand Down Expand Up @@ -46,6 +47,16 @@ func TestReachUnsafeTipByAppendingUnsafePayload(gt *testing.T) {
// while maintaining correct Engine API semantics.
func TestCLUnsafeNotRewoundOnInvalidDuringELSync(gt *testing.T) {
t := devtest.ParallelT(gt)
// Example error with op-reth:
//
// assertions.go:387: ERROR[03-31|09:41:58.089]
// assertions.go:387: Error Trace: /optimism/op-devstack/dsl/l2_cl.go:279
// assertions.go:387: /optimism/op-acceptance-tests/tests/sync/elsync/gap_clp2p/sync_test.go:96
// assertions.go:387: Error: Received unexpected error:
// assertions.go:387: expected head not to advance: unsafe
// assertions.go:387: Test: TestCLUnsafeNotRewoundOnInvalidDuringELSync
// assertions.go:387:
sysgo.SkipOnOpReth(t, "not supported")
sys := newGapCLP2PSystem(t)
logger := t.Logger()
require := t.Require()
Expand Down
Loading
Loading