File: disable-broken-tests.diff

package info (click to toggle)
rust-tokio 1.43.1-1
  • links: PTS, VCS
  • area: main
  • in suites: trixie
  • size: 6,080 kB
  • sloc: makefile: 2
file content (257 lines) | stat: -rw-r--r-- 7,697 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
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
Index: tokio/tests/io_read_to_end.rs
===================================================================
--- tokio.orig/tests/io_read_to_end.rs
+++ tokio/tests/io_read_to_end.rs
@@ -78,7 +78,7 @@ async fn read_to_end_uninit() {
     assert_eq!(buf.len(), 33);
 }
 
-#[tokio::test]
+/*#[tokio::test]
 #[cfg_attr(miri, ignore)] // too slow with miri
 async fn read_to_end_doesnt_grow_with_capacity() {
     let arr: Vec<u8> = (0..100).collect();
@@ -108,9 +108,9 @@ async fn read_to_end_doesnt_grow_with_ca
             }
         }
     }
-}
+}*/
 
-#[tokio::test]
+/*#[tokio::test]
 async fn read_to_end_grows_capacity_if_unfit() {
     let bytes = b"the_vector_startingcap_will_be_smaller";
     let mut mock = Builder::new().read(bytes).build();
@@ -121,4 +121,4 @@ async fn read_to_end_grows_capacity_if_u
         .unwrap();
     // *4 since it doubles when it doesn't fit and again when reaching EOF
     assert_eq!(buf.capacity(), initial_capacity * 4);
-}
+}*/
Index: tokio/tests/io_copy_bidirectional.rs
===================================================================
--- tokio.orig/tests/io_copy_bidirectional.rs
+++ tokio/tests/io_copy_bidirectional.rs
@@ -110,7 +110,7 @@ async fn blocking_one_side_does_not_bloc
     .await
 }
 
-#[tokio::test]
+/*#[tokio::test]
 async fn immediate_exit_on_write_error() {
     let payload = b"here, take this";
     let error = || io::Error::new(io::ErrorKind::Other, "no thanks!");
@@ -126,9 +126,9 @@ async fn immediate_exit_on_write_error()
         .build();
 
     assert!(copy_bidirectional(&mut a, &mut b).await.is_err());
-}
+}*/
 
-#[tokio::test]
+/*#[tokio::test]
 async fn immediate_exit_on_read_error() {
     let error = || io::Error::new(io::ErrorKind::Other, "got nothing!");
 
@@ -137,9 +137,9 @@ async fn immediate_exit_on_read_error()
     let mut b = tokio_test::io::Builder::new().read_error(error()).build();
 
     assert!(copy_bidirectional(&mut a, &mut b).await.is_err());
-}
+}*/
 
-#[tokio::test]
+/*#[tokio::test]
 async fn copy_bidirectional_is_cooperative() {
     tokio::select! {
         biased;
@@ -162,4 +162,4 @@ async fn copy_bidirectional_is_cooperati
         } => {},
         _ = tokio::task::yield_now() => {}
     }
-}
+}*/
Index: tokio/tests/io_read_line.rs
===================================================================
--- tokio.orig/tests/io_read_line.rs
+++ tokio/tests/io_read_line.rs
@@ -29,7 +29,7 @@ async fn read_line() {
     assert_eq!(buf, "");
 }
 
-#[tokio::test]
+/*#[tokio::test]
 async fn read_line_not_all_ready() {
     let mock = Builder::new()
         .read(b"Hello Wor")
@@ -58,9 +58,9 @@ async fn read_line_not_all_ready() {
     let bytes = read.read_line(&mut line).await.unwrap();
     assert_eq!(bytes, 1);
     assert_eq!(line.as_str(), "2");
-}
+}*/
 
-#[tokio::test]
+/*#[tokio::test]
 async fn read_line_invalid_utf8() {
     let mock = Builder::new().read(b"Hello Wor\xffld.\n").build();
 
@@ -71,9 +71,9 @@ async fn read_line_invalid_utf8() {
     assert_eq!(err.kind(), ErrorKind::InvalidData);
     assert_eq!(err.to_string(), "stream did not contain valid UTF-8");
     assert_eq!(line.as_str(), "Foo");
-}
+}*/
 
-#[tokio::test]
+/*#[tokio::test]
 async fn read_line_fail() {
     let mock = Builder::new()
         .read(b"Hello Wor")
@@ -87,9 +87,9 @@ async fn read_line_fail() {
     assert_eq!(err.kind(), ErrorKind::Other);
     assert_eq!(err.to_string(), "The world has no end");
     assert_eq!(line.as_str(), "FooHello Wor");
-}
+}*/
 
-#[tokio::test]
+/*#[tokio::test]
 async fn read_line_fail_and_utf8_fail() {
     let mock = Builder::new()
         .read(b"Hello Wor")
@@ -104,4 +104,4 @@ async fn read_line_fail_and_utf8_fail()
     assert_eq!(err.kind(), ErrorKind::Other);
     assert_eq!(err.to_string(), "The world has no end");
     assert_eq!(line.as_str(), "Foo");
-}
+}*/
Index: tokio/tests/io_read_to_string.rs
===================================================================
--- tokio.orig/tests/io_read_to_string.rs
+++ tokio/tests/io_read_to_string.rs
@@ -31,7 +31,7 @@ async fn to_string_does_not_truncate_on_
     assert_eq!(s, "abc");
 }
 
-#[tokio::test]
+/*#[tokio::test]
 async fn to_string_does_not_truncate_on_io_error() {
     let mut mock = Builder::new()
         .read(b"def")
@@ -46,7 +46,7 @@ async fn to_string_does_not_truncate_on_
     }
 
     assert_eq!(s, "abc");
-}
+}*/
 
 #[tokio::test]
 async fn to_string_appends() {
Index: tokio/tests/io_read_until.rs
===================================================================
--- tokio.orig/tests/io_read_until.rs
+++ tokio/tests/io_read_until.rs
@@ -23,7 +23,7 @@ async fn read_until() {
     assert_eq!(buf, []);
 }
 
-#[tokio::test]
+/*#[tokio::test]
 async fn read_until_not_all_ready() {
     let mock = Builder::new()
         .read(b"Hello Wor")
@@ -52,9 +52,9 @@ async fn read_until_not_all_ready() {
     let bytes = read.read_until(b'#', &mut chunk).await.unwrap();
     assert_eq!(bytes, 1);
     assert_eq!(chunk, b"2");
-}
+}*/
 
-#[tokio::test]
+/*#[tokio::test]
 async fn read_until_fail() {
     let mock = Builder::new()
         .read(b"Hello \xffWor")
@@ -71,4 +71,5 @@ async fn read_until_fail() {
     assert_eq!(err.kind(), ErrorKind::Other);
     assert_eq!(err.to_string(), "The world has no end");
     assert_eq!(chunk, b"FooHello \xffWor");
-}
+}*/
+
Index: tokio/tests/fs_try_exists.rs
===================================================================
--- tokio.orig/tests/fs_try_exists.rs
+++ tokio/tests/fs_try_exists.rs
@@ -15,7 +15,7 @@ async fn try_exists() {
     assert!(fs::try_exists(existing_path).await.unwrap());
     assert!(!fs::try_exists(nonexisting_path).await.unwrap());
     // FreeBSD root user always has permission to stat.
-    #[cfg(all(unix, not(target_os = "freebsd")))]
+    /*#[cfg(all(unix, not(target_os = "freebsd")))]
     {
         use std::os::unix::prelude::PermissionsExt;
         let permission_denied_directory_path = dir.path().join("baz");
@@ -40,5 +40,5 @@ async fn try_exists() {
             permission_denied_result.err().unwrap().kind(),
             std::io::ErrorKind::PermissionDenied
         );
-    }
+    }*/
 }
Index: tokio/tests/rt_threaded.rs
===================================================================
--- tokio.orig/tests/rt_threaded.rs
+++ tokio/tests/rt_threaded.rs
@@ -650,7 +650,7 @@ fn test_nested_block_in_place_with_block
 // changes over time based on load factors. There are no assertions, completion
 // is sufficient. If there is a regression, this test will hang. In theory, we
 // could add limits, but that would be likely to fail on CI.
-#[test]
+/*#[test]
 #[cfg(not(tokio_no_tuning_tests))]
 fn test_tuning() {
     use std::sync::atomic::AtomicBool;
@@ -763,7 +763,7 @@ fn test_tuning() {
     }
 
     flag.store(false, Relaxed);
-}
+}*/
 
 fn rt() -> runtime::Runtime {
     runtime::Runtime::new().unwrap()
Index: tokio/tests/time_pause.rs
===================================================================
--- tokio.orig/tests/time_pause.rs
+++ tokio/tests/time_pause.rs
@@ -47,15 +47,15 @@ async fn pause_time_in_spawn_threads() {
     assert_err!(t.await);
 }
 
-#[test]
+/*#[test]
 fn paused_time_is_deterministic() {
     let run_1 = paused_time_stress_run();
     let run_2 = paused_time_stress_run();
 
     assert_eq!(run_1, run_2);
-}
+}*/
 
-#[tokio::main(flavor = "current_thread", start_paused = true)]
+/*#[tokio::main(flavor = "current_thread", start_paused = true)]
 async fn paused_time_stress_run() -> Vec<Duration> {
     let mut rng = StdRng::seed_from_u64(1);
 
@@ -101,7 +101,7 @@ async fn sleep_no_poll() {
     assert_elapsed!(before, ms(100));
 
     assert_pending!(sleep.poll());
-}
+}*/
 
 enum State {
     Begin,