Documentation ¶
Index ¶
- type Cheat
- func (c *Cheat) ImpersonateAccountAndSendTransaction(from, to common.Address, value *big.Int, data []byte, gas uint64, ...) (txHash common.Hash, err error)
- func (c *Cheat) SendImpersonateTxn(from, to common.Address, value *big.Int, data []byte, gas uint64, ...) (txHash common.Hash, err error)
- func (c *Cheat) SetApprovalErc20(owner, token, spender common.Address, amount *big.Int) error
- func (c *Cheat) SetCode(account common.Address, code []byte) error
- func (c *Cheat) SetStorageAt(contractAddress common.Address, slotIdx, data common.Hash) error
- func (c *Cheat) StartImpersonateAccount(account common.Address) error
- func (c *Cheat) StopImpersonateAccount(account common.Address) error
- func (c *Cheat) TakeErc721Token(tokenAddress common.Address, tokenId *big.Int, receiver common.Address) error
- func (c *Cheat) WriteErc20Balance(contract, user common.Address, amount *big.Int) error
- func (c *Cheat) WriteNativeBalance(user common.Address, amount *big.Int) error
- type ForkCmd
- type ForkOpts
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Cheat ¶
type Cheat struct {
// contains filtered or unexported fields
}
func (*Cheat) ImpersonateAccountAndSendTransaction ¶
func (*Cheat) SendImpersonateTxn ¶
func (c *Cheat) SendImpersonateTxn(from, to common.Address, value *big.Int, data []byte, gas uint64, gasPrice *big.Int) (txHash common.Hash, err error)
make an impersonate txn
func (*Cheat) SetApprovalErc20 ¶
func (*Cheat) SetStorageAt ¶
set storge for an contract
func (*Cheat) StartImpersonateAccount ¶
after this call, all transactions from specified account can be executed without signing
func (*Cheat) StopImpersonateAccount ¶
stop impersonating account
func (*Cheat) TakeErc721Token ¶
func (*Cheat) WriteErc20Balance ¶
write balance of erc20 token for an account
Click to show internal directories.
Click to hide internal directories.