I have a smart contract that checks if the actual block number is higher than a fixed one to execute certain functionality and I need to write a unit test to validate that behavior. I’m using RSK in Regtest mode to execute tests and I would need to increment the block number without actually waiting for time to pass.
The smart contract uses a block number, and I need to increment the block number without actually waiting for time to pass.
context('once deployed', function () {
it('can only be released after cliff', async function () {
// TODO here I need to increment time or block number
await this.lockup.release();
});
)};
How can I do this in a truffle (mocha) test like the one above?