File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -895,7 +895,7 @@ pub struct SelfUpdateTestContext {
895895 pub config : Config ,
896896 _test_dir : TempDir ,
897897 #[ cfg( windows) ]
898- _registry_guard : Option < crate :: cli:: self_update:: RegistryGuard > ,
898+ _registry_guard : crate :: cli:: self_update:: RegistryGuard ,
899899 self_dist_tmp : TempDir ,
900900}
901901
@@ -949,7 +949,7 @@ pub struct CliTestContext {
949949 pub config : Config ,
950950 _test_dir : TempDir ,
951951 #[ cfg( windows) ]
952- _registry_guard : Option < crate :: cli:: self_update:: RegistryGuard > ,
952+ _registry_guard : crate :: cli:: self_update:: RegistryGuard ,
953953}
954954
955955impl CliTestContext {
@@ -974,7 +974,7 @@ impl CliTestContext {
974974 crate :: cli:: self_update:: RegistryGuard :: new ( [ & crate :: cli:: self_update:: USER_PATH ] )
975975 . unwrap ( ) ;
976976 config. set_registry_uuid ( & guard. uuid ) ;
977- Some ( guard)
977+ guard
978978 } ;
979979
980980 Self {
@@ -985,16 +985,6 @@ impl CliTestContext {
985985 }
986986 }
987987
988- #[ cfg( windows) ]
989- pub fn guard_registry (
990- & mut self ,
991- ids : impl IntoIterator < Item = & ' static crate :: cli:: self_update:: RegistryValueId > ,
992- ) {
993- let guard = crate :: cli:: self_update:: RegistryGuard :: new ( ids) . unwrap ( ) ;
994- self . config . set_registry_uuid ( & guard. uuid ) ;
995- self . _registry_guard = Some ( guard) ;
996- }
997-
998988 /// Move the dist server to the specified scenario and restore it
999989 /// afterwards.
1000990 pub fn with_dist_dir ( & mut self , scenario : Scenario ) -> DistDirGuard < ' _ > {
You can’t perform that action at this time.
0 commit comments