diff --git a/tests/suite/cli_self_upd.rs b/tests/suite/cli_self_upd.rs index e9cba3bc38b..03c8b1399c4 100644 --- a/tests/suite/cli_self_upd.rs +++ b/tests/suite/cli_self_upd.rs @@ -304,7 +304,24 @@ info: downloading self-update &["rustup", "self", "update"], &format!(" rustup updated - {version} (from {version})\n\n",), &expected_output, - ) + ); + + #[cfg(windows)] + { + use winreg::{enums::HKEY_CURRENT_USER, RegKey}; + + const RUSTUP_UNINSTALL_ENTRY: &str = + r"Software\Microsoft\Windows\CurrentVersion\Uninstall\Rustup"; + + assert_eq!( + RegKey::predef(HKEY_CURRENT_USER) + .open_subkey(RUSTUP_UNINSTALL_ENTRY) + .unwrap() + .get_value::("DisplayVersion") + .unwrap(), + version, + ) + } }); }