Skip to content

Commit 52616b9

Browse files
committed
Fix testing
Signed-off-by: Jiahao XU <[email protected]>
1 parent 76bb1aa commit 52616b9

File tree

2 files changed

+5
-2
lines changed

2 files changed

+5
-2
lines changed

src/lib.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -644,7 +644,7 @@ mod test {
644644
client.try_acquire().unwrap().unwrap();
645645
}
646646

647-
#[cfg(any(windows, target_os = "linux"))]
647+
#[cfg(windows)]
648648
#[test]
649649
fn test_try_acquire() {
650650
let client = Client::new(0).unwrap();

src/unix.rs

+4-1
Original file line numberDiff line numberDiff line change
@@ -612,13 +612,16 @@ mod test {
612612
run_named_fifo_try_acquire_tests(&new_client_from_fifo().0);
613613
}
614614

615-
#[cfg(not(target_os = "linux"))]
616615
#[test]
617616
fn test_try_acquire_annoymous_pipe_linux_specific_optimization() {
617+
#[cfg(not(target_os = "linux"))]
618618
assert_eq!(
619619
new_client_from_pipe().0.try_acquire().unwrap_err().kind(),
620620
io::ErrorKind::Unsupported
621621
);
622+
623+
#[cfg(target_os = "linux")]
624+
run_named_fifo_try_acquire_tests(&new_client_from_pipe().0);
622625
}
623626

624627
#[test]

0 commit comments

Comments
 (0)