Skip to main content

start_node

Function start_node 

Source
pub fn start_node() -> Result<(AnvilInstance, Url), TestnetError>
Expand description

Runs a local Anvil node bound to a specified IP address.

The AnvilInstance endpoint function is hardcoded to return “localhost”, so we must also return the RPC URL if we want to listen on a different address.

The anvil binary respects the ANVIL_IP_ADDR environment variable, but defaults to “localhost”.