Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 0 additions & 6 deletions src/librustuv/pipe.rs
Original file line number Diff line number Diff line change
Expand Up @@ -251,7 +251,6 @@ mod tests {
use super::super::local_loop;

#[test]
#[ignore(cfg(windows))] // FIXME(#10386): how windows pipes work
fn connect_err() {
match PipeWatcher::connect(local_loop(), &"path/to/nowhere".to_c_str()) {
Ok(*) => fail!(),
Expand All @@ -260,7 +259,6 @@ mod tests {
}

#[test]
#[ignore(cfg(windows))] // FIXME(#10386): how windows pipes work
fn bind_err() {
match PipeListener::bind(local_loop(), &"path/to/nowhere".to_c_str()) {
Ok(*) => fail!(),
Expand All @@ -269,7 +267,6 @@ mod tests {
}

#[test]
#[ignore(cfg(windows))] // FIXME(#10386): how windows pipes work
fn bind() {
let p = next_test_unix().to_c_str();
match PipeListener::bind(local_loop(), &p) {
Expand All @@ -279,15 +276,13 @@ mod tests {
}

#[test] #[should_fail]
#[ignore(cfg(windows))] // FIXME(#10386): how windows pipes work
fn bind_fail() {
let p = next_test_unix().to_c_str();
let _w = PipeListener::bind(local_loop(), &p).unwrap();
fail!();
}

#[test]
#[ignore(cfg(windows))] // FIXME(#10386): how windows pipes work
fn connect() {
let path = next_test_unix();
let path2 = path.clone();
Expand All @@ -313,7 +308,6 @@ mod tests {
}

#[test] #[should_fail]
#[ignore(cfg(windows))] // FIXME(#10386): how windows pipes work
fn connect_fail() {
let path = next_test_unix();
let path2 = path.clone();
Expand Down
6 changes: 5 additions & 1 deletion src/libstd/rt/test.rs
Original file line number Diff line number Diff line change
Expand Up @@ -375,7 +375,11 @@ pub fn next_test_port() -> u16 {
/// Get a temporary path which could be the location of a unix socket
#[fixed_stack_segment] #[inline(never)]
pub fn next_test_unix() -> Path {
os::tmpdir().join(rand::task_rng().gen_ascii_str(20))
if cfg!(unix) {
os::tmpdir().join(rand::task_rng().gen_ascii_str(20))
} else {
Path::new(r"\\.\pipe\" + rand::task_rng().gen_ascii_str(20))
}
}

/// Get a unique IPv4 localhost:port pair starting at 9600
Expand Down