Skip to main content

ping_test

Function ping_test 

Source
pub async fn ping_test(
    client: &Client,
    server: &Server,
) -> Result<(f64, f64, f64, Vec<f64>), SpeedtestError>
Expand description

Run a ping test against the given server, returning (average latency, jitter, packet_loss%, individual_samples).

ยงErrors

Returns SpeedtestError::NetworkError if all ping attempts fail.