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

[Do not merge] Simulated upgrade test for mainnet Gateway contract #1279

Open
wants to merge 61 commits into
base: main
Choose a base branch
from

Conversation

vgeddes
Copy link
Collaborator

@vgeddes vgeddes commented Aug 30, 2024

Uses Foundry's ability to run tests using storage forked from production networks.

Requirements:

  • Add MAINNET_RPC_URL to environment (I've updated Github Actions to include this secret)
  • Most recent foundry/forge version

Tasks

  • Upgrade production gateway use forking
  • Add sanity tests to ensure upgraded gateway is not compromised (storage corruption, etc).

@vgeddes vgeddes changed the title Simulated upgrade test for production Gateway contract Simulated upgrade test for mainnetGateway contract Aug 30, 2024
@vgeddes vgeddes changed the title Simulated upgrade test for mainnetGateway contract Simulated upgrade test for mainnet Gateway contract Aug 30, 2024
Comment on lines +78 to +79
/// Mock call to Verification.verifyCommitment to bypass BEEFY verification
vm.mockCall(VERIFICATION_ADDR, abi.encodeWithSelector(Verification.verifyCommitment.selector), abi.encode(true));
Copy link
Contributor

Choose a reason for hiding this comment

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

Cool! Another option is to use vm.startPrank(GatewayProxy) and test upgrade function directly. cf596f3

Base automatically changed from ron/polkadot-assets-on-ethereum to main September 2, 2024 09:00
@vgeddes vgeddes changed the title Simulated upgrade test for mainnet Gateway contract [Do not merge] Simulated upgrade test for mainnet Gateway contract Sep 3, 2024
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.

2 participants