Skip to content

Commit

Permalink
fix(mockCall): add missing check on alternative mockCall signature (#…
Browse files Browse the repository at this point in the history
  • Loading branch information
Evalir authored Jun 28, 2023
1 parent 31d6498 commit 3ae4c4b
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions evm/src/executor/inspector/cheatcodes/expect.rs
Original file line number Diff line number Diff line change
Expand Up @@ -509,6 +509,10 @@ pub fn apply<DB: DatabaseExt>(
Ok(Bytes::new())
}
HEVMCalls::MockCall1(inner) => {
if let Err(err) = data.journaled_state.load_account(h160_to_b160(inner.0), data.db) {
return Some(Err(err.into()))
}

state.mocked_calls.entry(inner.0).or_default().insert(
MockCallDataContext { calldata: inner.2.to_vec().into(), value: Some(inner.1) },
MockCallReturnData {
Expand Down

0 comments on commit 3ae4c4b

Please sign in to comment.