Documentation
¶
Index ¶
- func AddrFor(t *testing.T, dk *devkeys.MnemonicDevKeys, key devkeys.Key) common.Address
- func DefaultPrivkey(t *testing.T) (string, *ecdsa.PrivateKey, *devkeys.MnemonicDevKeys)
- func DeployDummyCaller(t *testing.T, rpcClient *rpc.Client, afactsFS foundry.StatDirFs, ...)
- func NewChainIntent(t *testing.T, dk *devkeys.MnemonicDevKeys, l1ChainID *big.Int, ...) *state.ChainIntent
- func NewIntent(t *testing.T, l1ChainID *big.Int, dk *devkeys.MnemonicDevKeys, ...) (*state.Intent, *state.State)
- func RunPastUpgrades(t *testing.T, host *script.Host, chainID uint64, prank common.Address, ...)
- func RunPastUpgradesWithRPC(t *testing.T, l1RPCUrl string, afactsFS foundry.StatDirFs, lgr log.Logger, ...)
- type ContractCaller
- type HostCaller
- type ImpersonationBroadcaster
- type RPCCaller
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func DefaultPrivkey ¶
func DefaultPrivkey(t *testing.T) (string, *ecdsa.PrivateKey, *devkeys.MnemonicDevKeys)
DefaultPrivkey returns the default private key for testing
func DeployDummyCaller ¶ added in v1.16.7
func DeployDummyCaller(t *testing.T, rpcClient *rpc.Client, afactsFS foundry.StatDirFs, prank, opcmAddr common.Address)
DeployDummyCaller deploys DummyCaller at the prank address with the given OPCM address.
func NewChainIntent ¶
func RunPastUpgrades ¶ added in v1.16.7
func RunPastUpgrades(t *testing.T, host *script.Host, chainID uint64, prank common.Address, systemConfigProxy common.Address)
RunPastUpgrades executes all past OPCM upgrades in-memory only (no broadcast). It fetches OPCM addresses from the superchain-registry, queries their actual versions on-chain, and applies upgrades in version order, skipping any that have already been applied.
func RunPastUpgradesWithRPC ¶ added in v1.16.7
func RunPastUpgradesWithRPC(t *testing.T, l1RPCUrl string, afactsFS foundry.StatDirFs, lgr log.Logger, chainID uint64, prank common.Address, systemConfigProxy common.Address)
RunPastUpgradesWithRPC runs past upgrades and broadcasts them using Anvil impersonation. It fetches OPCM data from the superchain-registry and applies upgrades in version order, skipping any upgrades that have already been applied based on SystemConfig.lastUsedOPCMVersion().
Types ¶
type ContractCaller ¶ added in v1.16.7
ContractCaller abstracts contract calls for both script.Host and ethclient.Client
type HostCaller ¶ added in v1.16.7
HostCaller adapts script.Host to ContractCaller
type ImpersonationBroadcaster ¶ added in v1.16.7
type ImpersonationBroadcaster struct {
// contains filtered or unexported fields
}
ImpersonationBroadcaster broadcasts transactions using Anvil impersonation.
func NewImpersonationBroadcaster ¶ added in v1.16.7
func (*ImpersonationBroadcaster) Broadcast ¶ added in v1.16.7
func (b *ImpersonationBroadcaster) Broadcast(ctx context.Context) ([]broadcaster.BroadcastResult, error)
func (*ImpersonationBroadcaster) Hook ¶ added in v1.16.7
func (b *ImpersonationBroadcaster) Hook(bcast script.Broadcast)