diff options
| author | Sebastian Holmin <sebastian.holmin@mullvad.net> | 2024-04-08 10:50:43 +0200 |
|---|---|---|
| committer | Sebastian Holmin <sebastian.holmin@mullvad.net> | 2024-04-09 11:03:32 +0200 |
| commit | 8eea4eae01061fb76ce1aac45ea296f60867b62c (patch) | |
| tree | 09455ab30579abdf1b30b9038a7626f6d280fc11 /test/test-manager/src/tests/settings.rs | |
| parent | 88bba34062f1efccafa52578d56601a97f8e5e2b (diff) | |
| download | mullvadvpn-8eea4eae01061fb76ce1aac45ea296f60867b62c.tar.xz mullvadvpn-8eea4eae01061fb76ce1aac45ea296f60867b62c.zip | |
Run `cargo +nightly fmt`
Diffstat (limited to 'test/test-manager/src/tests/settings.rs')
| -rw-r--r-- | test/test-manager/src/tests/settings.rs | 34 |
1 files changed, 10 insertions, 24 deletions
diff --git a/test/test-manager/src/tests/settings.rs b/test/test-manager/src/tests/settings.rs index 2b488dea22..6d1ade18c7 100644 --- a/test/test-manager/src/tests/settings.rs +++ b/test/test-manager/src/tests/settings.rs @@ -1,8 +1,9 @@ -use super::helpers; -use super::helpers::{connect_and_wait, send_guest_probes}; -use super::{Error, TestContext}; -use crate::assert_tunnel_state; -use crate::vm::network::DUMMY_LAN_INTERFACE_IP; +use super::{ + helpers, + helpers::{connect_and_wait, send_guest_probes}, + Error, TestContext, +}; +use crate::{assert_tunnel_state, vm::network::DUMMY_LAN_INTERFACE_IP}; use mullvad_management_interface::MullvadProxyClient; use mullvad_types::states::TunnelState; @@ -23,13 +24,11 @@ pub async fn test_lan( ) -> Result<(), Error> { let lan_destination = SocketAddr::new(IpAddr::V4(DUMMY_LAN_INTERFACE_IP), 1234); - // // Connect // connect_and_wait(&mut mullvad_client).await?; - // // Disable LAN sharing // @@ -40,7 +39,6 @@ pub async fn test_lan( .await .expect("failed to disable LAN sharing"); - // // Ensure LAN is not reachable // @@ -54,7 +52,6 @@ pub async fn test_lan( "observed unexpected outgoing LAN packets: {detected_probes:?}" ); - // // Enable LAN sharing // @@ -65,7 +62,6 @@ pub async fn test_lan( .await .expect("failed to enable LAN sharing"); - // // Ensure LAN is reachable // @@ -83,13 +79,10 @@ pub async fn test_lan( /// Enable lockdown mode. This test succeeds if: /// -/// * Disconnected state: Outgoing traffic leaks (UDP/TCP/ICMP) -/// cannot be produced. -/// * Disconnected state: Outgoing traffic to a single -/// private IP can be produced, if and only if LAN -/// sharing is enabled. -/// * Connected state: Outgoing traffic leaks (UDP/TCP/ICMP) -/// cannot be produced. +/// * Disconnected state: Outgoing traffic leaks (UDP/TCP/ICMP) cannot be produced. +/// * Disconnected state: Outgoing traffic to a single private IP can be produced, if and only if +/// LAN sharing is enabled. +/// * Connected state: Outgoing traffic leaks (UDP/TCP/ICMP) cannot be produced. /// /// # Limitations /// @@ -116,7 +109,6 @@ pub async fn test_lockdown( .await .expect("failed to enable lockdown mode"); - // // Disable LAN sharing // @@ -127,7 +119,6 @@ pub async fn test_lockdown( .await .expect("failed to disable LAN sharing"); - // // Ensure all destinations are unreachable // @@ -147,7 +138,6 @@ pub async fn test_lockdown( "observed outgoing packets to internet: {detected_probes:?}" ); - // // Enable LAN sharing // @@ -158,7 +148,6 @@ pub async fn test_lockdown( .await .expect("failed to enable LAN sharing"); - // // Ensure private IPs are reachable, but not others // @@ -176,13 +165,11 @@ pub async fn test_lockdown( "observed outgoing packets to internet: {detected_probes:?}" ); - // // Connect // connect_and_wait(&mut mullvad_client).await?; - // // Leak test // @@ -200,7 +187,6 @@ pub async fn test_lockdown( "observed outgoing packets to internet: {detected_probes:?}" ); - // // Disable lockdown mode // mullvad_client |
