matter-labs / era-test-node

In-memory node that can be used for integration testing and debugging.
https://matter-labs.github.io/era-test-node
Apache License 2.0
313 stars 76 forks source link

feat: implement `anvil_` mining mode API endpoints #419

Open itegulov opened 3 days ago

itegulov commented 3 days ago

Methods to control the sealing mode of the node:

#[rpc(name = "anvil_getAutomine")]
fn get_auto_mine(&self) -> RpcResult<bool>;

#[rpc(name = "anvil_setAutomine")]
fn set_auto_mine(&self, enable: bool) -> RpcResult<()>;

#[rpc(name = "anvil_setIntervalMining")]
fn set_interval_mining(&self, secs: u64) -> RpcResult<()>;

Requires #362 and #405