diff options
| author | Sebastian Holmin <sebastian.holmin@mullvad.net> | 2025-07-09 16:18:52 +0200 |
|---|---|---|
| committer | Sebastian Holmin <sebastian.holmin@mullvad.net> | 2025-07-10 09:37:02 +0200 |
| commit | 527c8daed79d37e2161e0ecb9bce20bd01b9ffc4 (patch) | |
| tree | 22fe8a41c6b5fa184780744388e2276e66ead9fa /test/test-runner/src/sys.rs | |
| parent | 3fd1c56d397375a494cf9279ed42122de8548579 (diff) | |
| download | mullvadvpn-527c8daed79d37e2161e0ecb9bce20bd01b9ffc4.tar.xz mullvadvpn-527c8daed79d37e2161e0ecb9bce20bd01b9ffc4.zip | |
Run `cargo fmt` in test-repo
Diffstat (limited to 'test/test-runner/src/sys.rs')
| -rw-r--r-- | test/test-runner/src/sys.rs | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/test/test-runner/src/sys.rs b/test/test-runner/src/sys.rs index 024e1153c9..a20a84cbaa 100644 --- a/test/test-runner/src/sys.rs +++ b/test/test-runner/src/sys.rs @@ -24,7 +24,7 @@ const MULLVAD_WIN_REGISTRY: &str = r"SYSTEM\CurrentControlSet\Services\Mullvad V pub fn reboot() -> Result<(), test_rpc::Error> { use windows_sys::Win32::{ System::Shutdown::{ - ExitWindowsEx, EWX_REBOOT, SHTDN_REASON_FLAG_PLANNED, SHTDN_REASON_MAJOR_APPLICATION, + EWX_REBOOT, ExitWindowsEx, SHTDN_REASON_FLAG_PLANNED, SHTDN_REASON_MAJOR_APPLICATION, SHTDN_REASON_MINOR_OTHER, }, UI::WindowsAndMessaging::EWX_FORCEIFHUNG, @@ -65,7 +65,7 @@ fn grant_shutdown_privilege() -> Result<(), test_rpc::Error> { use windows_sys::Win32::{ Foundation::{CloseHandle, HANDLE, LUID}, Security::{ - AdjustTokenPrivileges, LookupPrivilegeValueW, LUID_AND_ATTRIBUTES, + AdjustTokenPrivileges, LUID_AND_ATTRIBUTES, LookupPrivilegeValueW, SE_PRIVILEGE_ENABLED, TOKEN_ADJUST_PRIVILEGES, TOKEN_PRIVILEGES, }, System::{ @@ -501,7 +501,7 @@ pub async fn set_daemon_environment(env: HashMap<String, String>) -> Result<(), .map_err(|e| test_rpc::Error::Registry(e.to_string()))?; } // Persist the changed environment variables, such that we can retrieve them at will. - use winreg::{enums::*, RegKey}; + use winreg::{RegKey, enums::*}; let hklm = RegKey::predef(HKEY_LOCAL_MACHINE); let path = Path::new(MULLVAD_WIN_REGISTRY).join("Environment"); let (registry, _) = hklm.create_subkey(&path).map_err(|error| { @@ -636,7 +636,7 @@ fn parse_systemd_env_file(input: &str) -> impl Iterator<Item = EnvVar> + '_ { #[cfg(target_os = "windows")] pub async fn get_daemon_environment() -> Result<HashMap<String, String>, test_rpc::Error> { - use winreg::{enums::*, RegKey}; + use winreg::{RegKey, enums::*}; let env = tokio::task::spawn_blocking(|| -> Result<HashMap<String, String>, test_rpc::Error> { |
