Skip to content

feat(riscv-guest): l2 exec guest coverage test harness - #3784

Open
Filter94 wants to merge 2 commits into
mainfrom
test/l2-exec-guest-coverage-pr1-v2
Open

feat(riscv-guest): l2 exec guest coverage test harness#3784
Filter94 wants to merge 2 commits into
mainfrom
test/l2-exec-guest-coverage-pr1-v2

Conversation

@Filter94

Copy link
Copy Markdown
Contributor

This PR implements issue(s) #

Checklist

  • I wrote new tests for my new core changes.
  • I have successfully ran tests, style checker and build against my new changes locally.
  • If this change is deployed to any environment (including Devnet), E2E test coverage exists or is included in this
    PR.
  • I have informed the team of any breaking changes if there are any.

Copilot AI lite review requested due to automatic review settings August 13, 2026 09:36
@Filter94
Filter94 changed the base branch from main to feat/l2-execution-guest-rollup-v2 August 13, 2026 09:36
@Filter94 Filter94 changed the title Test/l2 exec guest coverage pr1 v2 feat(riscv-guest): l2 exec guest coverage test harness Aug 13, 2026

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR significantly expands the riscv-guests/l2-execution test and tooling surface to improve coverage and debuggability of the extended L2 execution guest, including (1) a test-only SSZ encoder for vanilla stateless inputs, (2) a conflation-plan DSL with scenario/parity tests, and (3) native host tools and JSON output support for local runs.

Changes:

  • Added a test-only SSZ encoder for vanilla StatelessInput plus round-trip and golden re-encode tests against EF fixtures.
  • Added a runL2ExecutionWithEngine seam and a conflation-plan DSL + scenario/parity tests to exercise conflation logic end-to-end on real bytes with a stubbed per-block engine.
  • Added native host tools (l2-execution-wrap, l2-execution-runner) and a JSON output encoder + golden test; wired new tests/tools/deps into build.zig.

Reviewed changes

Copilot reviewed 15 out of 15 changed files in this pull request and generated 3 comments.

Show a summary per file
File Description
riscv-guests/l2-execution/test/stateless_input_encode.zig Test-only SSZ encoder for vanilla StatelessInput wire format.
riscv-guests/l2-execution/test/stateless_input_encode_test.zig Round-trip + golden re-encode tests validating the encoder against the real decoder/fixtures.
riscv-guests/l2-execution/test/legacy_tx_rlp.zig Shared legacy transaction RLP builder for test fixtures.
riscv-guests/l2-execution/test/l2_execution_wrap.zig Native CLI tool to wrap vanilla inputs into extended inputs for the extended guest/harness.
riscv-guests/l2-execution/test/l2_execution_ssz_test.zig Unit tests for SSZ input/output encoding/decoding behavior.
riscv-guests/l2-execution/test/l2_execution_runner.zig Native CLI runner for extended guest logic with SSZ/JSON output toggle.
riscv-guests/l2-execution/test/l2_execution_range_test.zig Scenario suite exercising conflation logic over a realistic multi-block range plus mutation cases.
riscv-guests/l2-execution/test/l2_execution_json.zig JSON encoder for guest output (native-only convenience).
riscv-guests/l2-execution/test/l2_execution_json_test.zig Golden JSON shape test matching the Python reference output (minus proof metadata).
riscv-guests/l2-execution/test/conflation_plan.zig Conflation-plan DSL + stub engine to generate consistent inputs and drive conflation logic.
riscv-guests/l2-execution/test/conflation_plan_parity_test.zig Guards stub realism vs real execution seam + DSL smoke tests.
riscv-guests/l2-execution/src/l2_execution.zig Adds runL2ExecutionWithEngine seam and exposes internal helpers for tests via test_api.
riscv-guests/l2-execution/src/execution.zig Tightens pre-state root derivation: requires resolvable parent header witness for non-genesis.
riscv-guests/l2-execution/build.zig.zon Adds ssz.zig dependency (lazy) for test-only SSZ serialization.
riscv-guests/l2-execution/build.zig Wires in new tests/modules and installs new native tools.

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

Comment thread riscv-guests/l2-execution/build.zig.zon
Comment thread riscv-guests/l2-execution/src/l2_execution.zig Outdated
Comment thread riscv-guests/l2-execution/test/conflation_plan.zig
Filter94 added a commit that referenced this pull request Aug 13, 2026
Keeps the unit-test-only reflection surface out of the production
guest binary instead of exporting it unconditionally. Addresses a
Copilot review comment on PR #3784.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
gauravahuja
gauravahuja previously approved these changes Aug 19, 2026
Base automatically changed from feat/l2-execution-guest-rollup-v2 to main August 26, 2026 15:17
Filter94 and others added 2 commits August 26, 2026 17:17
Reintroduce l2_execution_ssz_test.zig and the JSON/runner/wrap host
tooling (relocated from the base branch, unmodified) alongside this
PR's own seam-injection DSL (runL2ExecutionWithEngine, ConflationPlan,
parity guard, range scenarios) and the vanilla StatelessInput SSZ
encoder. Rename conflation_plan.zig's reused zero_hash/zero_addr
locals to distinct per-field names instead of leaning on 16 trailing
index comments to disambiguate them.
Keeps the unit-test-only reflection surface out of the production
guest binary instead of exporting it unconditionally. Addresses a
Copilot review comment on PR #3784.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
@Filter94
Filter94 force-pushed the test/l2-exec-guest-coverage-pr1-v2 branch from cdd3579 to 36a2bca Compare August 26, 2026 15:17
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.

3 participants