wait_until_console_output

Function wait_until_console_output 

Source
pub fn wait_until_console_output(
    dbg: bool,
    container_id: &str,
    expected_output: &str,
    timeout: &u64,
) -> Result<(), WaitStrategyError>
Expand description

Waits until the console output of the container with the given ID contains the specified expected output. If the expected output is not found within the given timeout, an error is returned.

§Arguments

  • container_id - The ID of the container whose console output to check.
  • expected_output - The string to search for in the console output.
  • timeout - The timeout duration in seconds.

§Returns

Returns Ok(()) if the expected output is found within the timeout, or an Err(DockerError) if the expected output is not found.