From a69cdb0426a697c79cd3d3ea89c52cc4b72ea019 Mon Sep 17 00:00:00 2001 From: Sebastian Holmin Date: Mon, 8 Jan 2024 14:27:02 +0100 Subject: [PATCH] fixup! Update the tunnel state on lockdown mode change. --- test/test-manager/src/tests/helpers.rs | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) diff --git a/test/test-manager/src/tests/helpers.rs b/test/test-manager/src/tests/helpers.rs index f697900e0db4..ddedd96ae16d 100644 --- a/test/test-manager/src/tests/helpers.rs +++ b/test/test-manager/src/tests/helpers.rs @@ -229,7 +229,7 @@ pub async fn disconnect_and_wait( .await .map_err(|error| Error::Daemon(format!("failed to begin disconnecting: {}", error)))?; wait_for_tunnel_state(mullvad_client.clone(), |state| { - matches!(state, TunnelState::Disconnected(_)) + matches!(state, TunnelState::Disconnected { .. }) }) .await?; @@ -347,10 +347,10 @@ impl Drop for AbortOnDrop { /// * Provider constraint is [`Constraint::Any`] /// * Ownership constraint is [`Constraint::Any`] /// * The default tunnel protocol is [`talpid_types::net::TunnelType::Wireguard`] -/// * Wireguard settings are default (i.e. any port is used, no obfuscation ..) -/// see [`mullvad_types::relay_constraints::WireguardConstraints`] for details. -/// * OpenVPN settings are default (i.e. any port is used, no obfuscation ..) -/// see [`mullvad_types::relay_constraints::OpenVpnConstraints`] for details. +/// * Wireguard settings are default (i.e. any port is used, no obfuscation ..) see +/// [`mullvad_types::relay_constraints::WireguardConstraints`] for details. +/// * OpenVPN settings are default (i.e. any port is used, no obfuscation ..) see +/// [`mullvad_types::relay_constraints::OpenVpnConstraints`] for details. pub async fn reset_relay_settings( mullvad_client: &mut ManagementServiceClient, ) -> Result<(), Error> { @@ -559,8 +559,9 @@ impl Pinger { log::debug!("Monitoring outgoing traffic"); let monitor = start_packet_monitor( move |packet| { - // NOTE: Many packets will likely be observed for API traffic. Rather than filtering all - // of those specifically, simply fail if our probes are observed. + // NOTE: Many packets will likely be observed for API traffic. Rather than filtering + // all of those specifically, simply fail if our probes are + // observed. packet.source.ip() == guest_ip && packet.destination.ip() == builder.destination.ip() },