Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(Vm): Add new expectCall variants #310

Merged

Conversation

clabby
Copy link
Contributor

@clabby clabby commented Feb 23, 2023

Overview

Sister PR to foundry-rs/foundry#4413

Adds two new variants of the expectCall cheatcode that allows for asserting the amount of gas passed to a call.

// Expect a call to an address with the specified msg.value, gas, and calldata.
function expectCall(address callee, uint256 msgValue, uint64 gas, bytes calldata data) external;

// Expect a call to an address with the specified msg.value and calldata, and a *minimum* amount of gas.
function expectCallMinGas(address callee, uint256 msgValue, uint64 minGas, bytes calldata data) external;

Copy link
Collaborator

@mds1 mds1 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks!

@mds1 mds1 merged commit fd86115 into foundry-rs:master Feb 24, 2023
@clabby clabby deleted the clabby/new-expect-call-cheat-variants branch February 24, 2023 15:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants