Skip to main content

Module evm

Module evm 

Source
Expand description

Implementations of Evm cheatcodes.

ModulesΒ§

fork πŸ”’
mapping πŸ”’
mock πŸ”’
prank πŸ”’
record_debug_step πŸ”’

StructsΒ§

AccountStateDiffs πŸ”’
Account state diff info.
BalanceDiff πŸ”’
Balance diff info.
DealRecord
Records deal cheatcodes
GasRecord
Records the snapshotGas* cheatcodes.
LogJson πŸ”’
JSON-serializable log entry for getRecordedLogsJson.
NonceDiff πŸ”’
Nonce diff info.
RecordAccess
Records storage slots reads and writes.
SlotStateDiff πŸ”’
Storage slot diff info.
StateDump πŸ”’

ConstantsΒ§

EIP1822_PROXIABLE_SLOT πŸ”’
EIP-1822 UUPS implementation storage slot: keccak256(β€œPROXIABLE”)
EIP1967_IMPL_SLOT πŸ”’
EIP-1967 implementation storage slot
TIP20_LOGO_URI_SLOT_INDEX πŸ”’

FunctionsΒ§

append_storage_access πŸ”’
Appends an AccountAccess that resumes the recording of the current context.
cleanup_long_string_tail πŸ”’
clear_eip2935_history_storage πŸ”’
Clears the EIP-2935 history ring buffer with journaled writes, so that reverting the enclosing frame restores the previous history storage.
derive_snapshot_name πŸ”’
encode_short_string πŸ”’
ensure_loaded_account πŸ”’
genesis_account πŸ”’
Helper function that creates a GenesisAccount from a regular Account.
get_contract_data πŸ”’
Helper function to get the contract data from the deployed code at an address.
get_nonce πŸ”’
get_recorded_state_diffs πŸ”’
Helper function to returns state diffs recorded for each changed account.
get_state_diff πŸ”’
Consumes recorded account accesses and returns them as an abi encoded array of AccountAccess. If there are no accounts were recorded as accessed, an abi encoded empty array is returned.
inner_last_gas_snapshot πŸ”’
inner_revert_to_state πŸ”’
inner_revert_to_state_and_delete πŸ”’
inner_snapshot_state πŸ”’
inner_start_gas_snapshot πŸ”’
inner_stop_gas_snapshot πŸ”’
inner_value_snapshot πŸ”’
is_long_string πŸ”’
journaled_account πŸ”’
Ensures the Account is loaded and touched.
long_string_length πŸ”’
mark_account_accesses_reverted πŸ”’
Marks a reverted frame’s account accesses, including their storage accesses, as reverted.
merge_recorded_frame πŸ”’
Moves a finished frame’s account accesses into the enclosing recorded frame, or back onto the stack when no enclosing frame was recorded, preserving the order of the accesses.
read_callers πŸ”’
Reads the current caller information and returns the current CallerMode, msg.sender and tx.origin.
restore_eip2935_cold_state πŸ”’
restore_isolation_fee_accounting πŸ”’
set_cold_slot πŸ”’
Helper function to set / unset cold storage slot of the target address.
set_eip2935_blockhash πŸ”’
set_tip20_logo_uri πŸ”’
solidity_dynamic_data_slot πŸ”’
store_solidity_string πŸ”’
string_chunks πŸ”’
sync_tx_after_env_override_restore πŸ”’
Syncs the real tx fields to match restored env_overrides.
track_snapshot_restore πŸ”’
Records the live journal replaced by a snapshot restoration so that a failing enclosing frame can reinstate it and unwind its journaled writes.