package tezt-tezos

  1. Overview
  2. Docs

Module Tezt_tezos.Dal_nodeSource

Spawn Data-availability-layer (DAL) nodes and control them

Sourcetype t

DAL Node state

Creates a DAL node

Sourceval create : ?path:string -> ?name:string -> ?color:Tezt.Log.Color.t -> ?data_dir:string -> ?event_pipe:string -> ?rpc_host:string -> ?rpc_port:int -> ?listen_addr:string -> node:Node.t -> client:Client.t -> unit -> t
Sourceval name : t -> string

Get the name of an dal node.

Sourceval rpc_host : t -> string

Get the RPC host given as --rpc-addr to an dal node.

Sourceval rpc_port : t -> int

Get the RPC port given as --rpc-addr to an dal node.

Sourceval endpoint : t -> string

Return the endpoint of the dal node, i.e., http://rpc_host:rpc_port.

Sourceval data_dir : t -> string

Get the data-dir of an dal node.

Sourceval run : ?wait_ready:bool -> ?env:string Tezt.Base.String_map.t -> t -> unit Lwt.t

run ?wait_ready ?env node launches the given dal node where env is a map of environment variable.

If wait_ready is true, the promise waits for the dal node to be ready. true by default.

Sourceval terminate : ?timeout:float -> t -> unit Lwt.t

Send SIGTERM and wait for the process to terminate.

Default timeout is 30 seconds, after which SIGKILL is sent.

Sourceval kill : t -> unit Lwt.t

Send SIGKILL and wait for the process to terminate.

Sourceval log_events : t -> unit

Shows in stdout every events sent by the node

Sourceval wait_for : ?where:string -> t -> string -> (Tezt.JSON.t -> 'a option) -> 'a Lwt.t

See Daemon.Make.wait_for.

Sourceval is_running_not_ready : t -> bool

is_running_not_ready dal_node returns true if the given node is running but its status is not ready

Sourceval wait : t -> Unix.process_status Lwt.t

Wait until a node terminates and return its status. If the node is not running, make the test fail.

Sourceval init_config : ?use_unsafe_srs:bool -> t -> string Lwt.t

Run octez-dal-node init-config. Returns the name of the resulting configuration file.

If use_unsafe_srs is true, the dal node runs with unsafe computed SRS allowing tests to run faster, without the need of large file. Default is true in tezt.

Sourcemodule Config_file : sig ... end

DAL node configuration files.