Struct evm_adapters::evmodin::EvmOdin [−][src]
pub struct EvmOdin<S, T> {
pub host: S,
pub gas_limit: u64,
pub call_kind: Option<CallKind>,
pub revision: Revision,
pub tracer: T,
}
Expand description
Wrapper around EVModin which implements the Evm trait
Fields
host: S
gas_limit: u64
call_kind: Option<CallKind>
revision: Revision
tracer: T
Implementations
Trait Implementations
Grabs debug steps
Runs the selected function
type ReturnReason = StatusCode
type ReturnReason = StatusCode
The returned reason type from an EVM (Success / Revert/ Stopped etc.)
Gets the revert reason type
Whether a return reason should be considered successful
Whether a return reason should be considered failing
Sets the balance at the specified address
Turns on/off tracing, returning the previously set value
Returns whether tracing is enabled
Sets the provided contract bytecode at the corresponding addresses
Deploys the provided contract bytecode and returns the address
Performs a call_unchecked
, checks if execution reverted, and
proceeds to return the decoded response to the user. Read more
Executes the specified EVM call against the state
Runs the setUp()
function call to instantiate the contract’s state
Runs the failed()
function call to inspect the test contract’s state and
see whether the failed
state var is set. This is to allow compatibility
with dapptools-style DSTest smart contracts to preserve emiting of logs Read more
fn check_success(
&mut self,
address: Address,
reason: &Self::ReturnReason,
should_fail: bool
) -> bool
fn check_success(
&mut self,
address: Address,
reason: &Self::ReturnReason,
should_fail: bool
) -> bool
Given a smart contract address, the result type and whether it’s expected to fail, it returns the test’s success status Read more
Auto Trait Implementations
impl<S, T> RefUnwindSafe for EvmOdin<S, T> where
S: RefUnwindSafe,
T: RefUnwindSafe,
impl<S, T> UnwindSafe for EvmOdin<S, T> where
S: UnwindSafe,
T: UnwindSafe,
Blanket Implementations
Mutably borrows from an owned value. Read more
Instruments this type with the provided Span
, returning an
Instrumented
wrapper. Read more
Attaches the provided Subscriber
to this type, returning a
WithDispatch
wrapper. Read more
Attaches the current default Subscriber
to this type, returning a
WithDispatch
wrapper. Read more