Currently there are multiple flavors of expectCall, but all of them treat empty data as a request to not check the calldata content. The problem is that there's no way to check if calldata is empty, e.g. because a native token transfer was made. The current expectCall API surface doesn't leave much space for adding this feature.
I propose adding a new set of expectTransfer functions. They would be identical to expectCall with all their variants, but they wouldn't have the data parameter, and they would expect that the address is called with zero-length calldata.
Currently there are multiple flavors of
expectCall
, but all of them treat emptydata
as a request to not check the calldata content. The problem is that there's no way to check if calldata is empty, e.g. because a native token transfer was made. The currentexpectCall
API surface doesn't leave much space for adding this feature.I propose adding a new set of
expectTransfer
functions. They would be identical toexpectCall
with all their variants, but they wouldn't have thedata
parameter, and they would expect that the address is called with zero-length calldata.