File: remove-gix-testtools.patch

package info (click to toggle)
rust-gix-path 0.10.21-2
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 356 kB
  • sloc: makefile: 2
file content (179 lines) | stat: -rw-r--r-- 4,714 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
--- a/Cargo.toml
+++ b/Cargo.toml
@@ -53,6 +53,9 @@
 version = "3.1.0"
 default-features = false
 
+[dev-dependencies.tempfile]
+version = "3"
+
 [target.'cfg(not(target_family = "wasm"))'.dependencies.home]
 version = "0.5.5"
 
--- a/src/env/git/tests.rs
+++ b/src/env/git/tests.rs
@@ -742,7 +742,7 @@
 mod exe_info {
     use std::path::{Path, PathBuf};
 
-    use gix_testtools::tempfile;
+    use tempfile;
     use serial_test::serial;
 
     use crate::env::git::{exe_info, NULL_DEVICE};
@@ -777,7 +777,7 @@
         }
     }
 
-    fn set_temp_env_vars<'a>(path: &Path) -> gix_testtools::Env<'a> {
+    /*fn set_temp_env_vars<'a>(path: &Path) -> gix_testtools::Env<'a> {
         let path_str = path.to_str().expect("valid Unicode");
 
         let env = gix_testtools::Env::new()
@@ -792,11 +792,11 @@
         );
 
         env
-    }
+    }*/
 
-    fn unset_windows_directory_vars<'a>() -> gix_testtools::Env<'a> {
+    /*fn unset_windows_directory_vars<'a>() -> gix_testtools::Env<'a> {
         gix_testtools::Env::new().unset("windir").unset("SystemRoot")
-    }
+    }*/
 
     fn check_exe_info() {
         let path = exe_info()
@@ -819,31 +819,31 @@
         check_exe_info();
     }
 
-    #[test]
+    /*#[test]
     #[serial]
     fn tolerates_broken_temp() {
         let non = NonexistentLocation::new();
         let _env = set_temp_env_vars(non.path());
         check_exe_info();
-    }
+    }*/
 
-    #[test]
+    /*#[test]
     #[serial]
     fn tolerates_oversanitized_env() {
         // This test runs on all systems, but it is only checking for a Windows regression. Also, on
         // Windows, having both a broken temp dir and an over-sanitized environment is not supported.
         let _env = unset_windows_directory_vars();
         check_exe_info();
-    }
+    }*/
 
-    #[test]
+    /*#[test]
     #[serial]
     fn tolerates_git_config_env_var() {
         let _env = gix_testtools::Env::new().set("GIT_CONFIG", NULL_DEVICE);
         check_exe_info();
-    }
+    }*/
 
-    #[test]
+    /*#[test]
     #[serial]
     fn same_result_with_broken_temp() {
         let with_unmodified_temp = exe_info();
@@ -855,9 +855,9 @@
         };
 
         assert_eq!(with_unmodified_temp, with_nonexistent_temp);
-    }
+    }*/
 
-    #[test]
+    /*#[test]
     #[serial]
     fn same_result_with_oversanitized_env() {
         let with_unmodified_env = exe_info();
@@ -868,9 +868,9 @@
         };
 
         assert_eq!(with_unmodified_env, with_oversanitized_env);
-    }
+    }*/
 
-    #[test]
+    /*#[test]
     #[serial]
     fn same_result_with_git_config_env_var() {
         let with_unmodified_env = exe_info();
@@ -881,9 +881,9 @@
         };
 
         assert_eq!(with_unmodified_env, with_git_config_env_var);
-    }
+    }*/
 
-    #[test]
+    /*#[test]
     #[serial]
     #[cfg(not(target_os = "macos"))] // Assumes no higher "unknown" scope. The `nosystem` case works.
     fn never_from_local_scope() {
@@ -899,9 +899,9 @@
             maybe_path, None,
             "Should find no config path if the config would be local (empty system config)"
         );
-    }
+    }*/
 
-    #[test]
+    /*#[test]
     #[serial]
     fn never_from_local_scope_nosystem() {
         let repo = gix_testtools::scripted_fixture_read_only("local_config.sh").expect("script succeeds");
@@ -916,9 +916,9 @@
             maybe_path, None,
             "Should find no config path if the config would be local (suppressed system config)"
         );
-    }
+    }*/
 
-    #[test]
+    /*#[test]
     #[serial]
     #[cfg(not(target_os = "macos"))] // Assumes no higher "unknown" scope. The `nosystem` case works.
     fn never_from_local_scope_even_if_temp_is_here() {
@@ -937,9 +937,9 @@
             maybe_path, None,
             "Should find no config path if the config would be local even in a `/tmp`-like dir (empty system config)"
         );
-    }
+    }*/
 
-    #[test]
+    /*#[test]
     #[serial]
     fn never_from_local_scope_even_if_temp_is_here_nosystem() {
         let repo = gix_testtools::scripted_fixture_read_only("local_config.sh")
@@ -957,9 +957,9 @@
             maybe_path, None,
             "Should find no config path if the config would be local even in a `/tmp`-like dir (suppressed system config)"
         );
-    }
+    }*/
 
-    #[test]
+    /*#[test]
     #[serial]
     fn never_from_git_config_env_var() {
         let repo = gix_testtools::scripted_fixture_read_only("local_config.sh").expect("script succeeds");
@@ -984,7 +984,7 @@
             maybe_path, None,
             "Should find no config path from GIT_CONFIG (even if nonempty)"
         );
-    }
+    }*/
 
     #[test]
     fn first_file_from_config_with_origin() {