0.0.12 • Published 2 years ago
@therealbytes/ticking-wrapper v0.0.12
Ticking wrapper
Wrap an ethereum devnet node to emulate a ticking chain.
Install
yarn add --dev @therealbytes/ticking-wrapper
Start chain
npx ticking --tick-gas-limit=<tick gas limit> anvil <anvil command line parameters>
Make sure to set the values of ticking command line parameters with equals signs, not a space. --tick-gas-limit=X
, not --tick-gas-limit X
.
Set the tick target (must follow the tick interface)
cast send \
--private-key ac0974bec39a17e36ba4a6b4d238ff944bacb478cbed5efcae784d7bf4f2ff80 \
0x42000000000000000000000000000000000000A0 \
'setTarget(address)' \
<CONTRACT_ADDRESS>
Every block will include a transaction calling tick()
in the tick pre-deploy, which will call tick()
in the target contract if it is set.
Supported nodes:
- Anvil
- Hardhat (coming soon)
More
Tick interface
interface ITick {
function tick() external;
}