Skip to content

test: skip deployPayloads for pre-set spell addresses - #180

Open
piyushbag wants to merge 1 commit into
sparkdotfi:masterfrom
piyushbag:fix/90-predeployed-payloads
Open

test: skip deployPayloads for pre-set spell addresses#180
piyushbag wants to merge 1 commit into
sparkdotfi:masterfrom
piyushbag:fix/90-predeployed-payloads

Conversation

@piyushbag

@piyushbag piyushbag commented Jul 21, 2026

Copy link
Copy Markdown

Summary

  • Skip _deployPayloads when a chain payload address is already configured
  • Add _setPayloadAddress helper for spell tests using deployed mainnet payloads
  • Migrate Spell_20260716 tests to set payload addresses in constructors

Test plan

  • forge build

Summary by CodeRabbit

  • Tests
    • Improved spell test setup to recognize payloads that are already deployed on supported networks.
    • Prevented unnecessary payload redeployment during test execution.
    • Added support for configuring existing payload addresses across Ethereum, Robinhood, and XLayer environments.

Allow spell tests to register on-chain payload addresses before setUp and skip redeploying them.

Fixes sparkdotfi#90
@octane-security-app

Copy link
Copy Markdown

Summary by Octane

New Contracts

No new contracts were added.

Updated Contracts

  • SpellRunner.sol: Added functionality to skip chains with existing payloads and a new method to set payload addresses for chains directly.

🔗 Commit Hash: ca4b4cb

@coderabbitai

coderabbitai Bot commented Jul 21, 2026

Copy link
Copy Markdown

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Repository UI

Review profile: CHILL

Plan: Pro

Run ID: 7c615283-6f81-437e-bf38-a675d299c654

📥 Commits

Reviewing files that changed from the base of the PR and between c24ddf5 and ca4b4cb.

📒 Files selected for processing (2)
  • src/proposals/20260716/Spell_20260716.t.sol
  • src/test-harness/SpellRunner.sol

Walkthrough

Changes

Payload preconfiguration

Layer / File(s) Summary
Harness payload handling
src/test-harness/SpellRunner.sol
_deployPayloads() skips chains with configured payloads, and _setPayloadAddress() directly records existing payload addresses.
Spell test payload initialization
src/proposals/20260716/Spell_20260716.t.sol
Three test contracts configure Ethereum, Robinhood, and XLayer payload addresses in constructors instead of setUp().

Estimated code review effort: 2 (Simple) | ~10 minutes

Possibly related PRs

Suggested reviewers: supercontracts, certora-spark-review, themj0ln1r

Poem

I hop through payloads, tidy and bright,
Skipping old deployments already right.
Three constructors bloom with addresses in place,
Ethereum, Robinhood, XLayer keep pace.
A bunny reviews with a cheerful embrace.

🚥 Pre-merge checks | ✅ 3 | ❌ 2

❌ Failed checks (2 warnings)

Check name Status Explanation Resolution
Title check ⚠️ Warning The title is descriptive but missing the required Linear issue identifier suffix. Append the required issue key in parentheses, e.g. test: skip deployPayloads for pre-set spell addresses (SC-1234).
Description check ⚠️ Warning The description only includes Summary and Test plan, leaving most required template sections empty. Add the forum post, dependencies, addresses table, reviewer notes, and deployment/handoff/merge conditions from the template.
✅ Passed checks (3 passed)
Check name Status Explanation
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

Comment @coderabbitai help to get the list of available commands.

@octane-security-app

Copy link
Copy Markdown

Overview

Warnings found: 1                                                                                

🔗 Commit Hash: ca4b4cb
🛡️ Octane Dashboard: All vulnerabilities

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.

1 participant