Sitelet https://hardhat.org/docs/reference/cheatcodes/environment/set-blockhash
Skip to content

setBlockhash

function setBlockhash(uint256 blockNumber, bytes32 blockHash) external;

Set blockhash for the current block. It only sets the blockhash for blocks where block.number - 256 <= number < block.number.