summaryrefslogtreecommitdiff
path: root/test/test_poll.rs
diff options
context:
space:
mode:
authorCostin-Robert Sin <sin.costinrobert@gmail.com>2022-06-21 15:36:05 +0300
committerCostin-Robert Sin <sin.costinrobert@gmail.com>2022-06-24 00:35:52 +0300
commit3e6cb639f0d9afde57d9cc03526c2e488641231b (patch)
treec882f2947fa5b22e67a58918c45012655b892b30 /test/test_poll.rs
parent8f08a69c28fad5ee875d69e4c8a1b8eed2203cb4 (diff)
downloadnix-3e6cb639f0d9afde57d9cc03526c2e488641231b.zip
Fix all formating problems to pass CI formating test
Signed-off-by: Costin-Robert Sin <sin.costinrobert@gmail.com>
Diffstat (limited to 'test/test_poll.rs')
-rw-r--r--test/test_poll.rs18
1 files changed, 10 insertions, 8 deletions
diff --git a/test/test_poll.rs b/test/test_poll.rs
index 120e8e56..53964e26 100644
--- a/test/test_poll.rs
+++ b/test/test_poll.rs
@@ -1,7 +1,7 @@
use nix::{
errno::Errno,
- poll::{PollFlags, poll, PollFd},
- unistd::{write, pipe}
+ poll::{poll, PollFd, PollFlags},
+ unistd::{pipe, write},
};
macro_rules! loop_while_eintr {
@@ -10,10 +10,10 @@ macro_rules! loop_while_eintr {
match $poll_expr {
Ok(nfds) => break nfds,
Err(Errno::EINTR) => (),
- Err(e) => panic!("{}", e)
+ Err(e) => panic!("{}", e),
}
}
- }
+ };
}
#[test]
@@ -37,10 +37,12 @@ fn test_poll() {
// ppoll(2) is the same as poll except for how it handles timeouts and signals.
// Repeating the test for poll(2) should be sufficient to check that our
// bindings are correct.
-#[cfg(any(target_os = "android",
- target_os = "dragonfly",
- target_os = "freebsd",
- target_os = "linux"))]
+#[cfg(any(
+ target_os = "android",
+ target_os = "dragonfly",
+ target_os = "freebsd",
+ target_os = "linux"
+))]
#[test]
fn test_ppoll() {
use nix::poll::ppoll;