Skip to content

Commit 68a4f7d

Browse files
committed
auto merge of #12523 : alexcrichton/rust/ignore-some-windows-tests, r=pnkfelix
These two tests are notoriously flaky on the windows bots right now, so I'm ignoring them until I can investigate them some more. The truncate_works test has been flaky for quite some time, but it has gotten much worse recently. The test_exists test has been flaky since the recent std::run rewrite landed. Finally, the "unix pipe" test failure is a recent discovery on the try bots. I haven't seen this failing much, but better safe than sorry! cc #12516
2 parents 6720977 + 13a8fcd commit 68a4f7d

File tree

3 files changed

+7
-6
lines changed

3 files changed

+7
-6
lines changed

src/libstd/io/fs.rs

+2-3
Original file line numberDiff line numberDiff line change
@@ -1106,9 +1106,8 @@ mod test {
11061106
file.fsync().unwrap();
11071107
file.datasync().unwrap();
11081108
drop(file);
1109-
})
1109+
} #[ignore(cfg(windows))])
11101110

1111-
#[ignore(cfg(windows))] // FIXME(#11638)
11121111
iotest!(fn truncate_works() {
11131112
let tmpdir = tmpdir();
11141113
let path = tmpdir.join("in.txt");
@@ -1138,7 +1137,7 @@ mod test {
11381137
assert_eq!(File::open(&path).read_to_end().unwrap(),
11391138
(bytes!("fo", 0, 0, 0, 0, "wut")).to_owned());
11401139
drop(file);
1141-
})
1140+
} #[ignore(cfg(windows))]) // FIXME(#11638)
11421141

11431142
iotest!(fn open_flavors() {
11441143
let tmpdir = tmpdir();

src/libstd/io/net/unix.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -192,7 +192,7 @@ mod tests {
192192
}, proc(_client) {
193193
// drop the client
194194
})
195-
})
195+
} #[ignore(cfg(windows))]) // FIXME(#12516)
196196

197197
iotest!(fn write_begone() {
198198
smalltest(proc(mut server) {

src/libstd/io/process.rs

+4-2
Original file line numberDiff line numberDiff line change
@@ -814,7 +814,10 @@ mod tests {
814814
}
815815
#[cfg(windows)]
816816
pub fn sleeper() -> Process {
817-
Process::new("timeout", [~"1000"]).unwrap()
817+
// There's a `timeout` command on windows, but it doesn't like having
818+
// its output piped, so instead just ping ourselves a few times with
819+
// gaps inbetweeen so we're sure this process is alive for awhile
820+
Process::new("ping", [~"127.0.0.1", ~"-n", ~"1000"]).unwrap()
818821
}
819822

820823
iotest!(fn test_kill() {
@@ -823,7 +826,6 @@ mod tests {
823826
assert!(!p.wait().success());
824827
})
825828

826-
#[ignore(cfg(windows))]
827829
iotest!(fn test_exists() {
828830
let mut p = sleeper();
829831
assert!(Process::kill(p.id(), 0).is_ok());

0 commit comments

Comments
 (0)