diff options
author | Alan Somers <asomers@gmail.com> | 2021-08-22 09:17:05 -0600 |
---|---|---|
committer | Alan Somers <asomers@gmail.com> | 2021-08-22 10:31:39 -0600 |
commit | f3cb6b321fa1e16dc14b9bcdc37f001375a8c85c (patch) | |
tree | 204a669147d64f9b928660685cb4f0920a0f4e4a /test/test_time.rs | |
parent | 28f547fa120cf842278c6749254edcd0ce6fea6a (diff) | |
download | nix-f3cb6b321fa1e16dc14b9bcdc37f001375a8c85c.zip |
Fix building the tests for Redox and Illumos
Also, split the overbroad test_mknod_family into two tests
Diffstat (limited to 'test/test_time.rs')
-rw-r--r-- | test/test_time.rs | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/test/test_time.rs b/test/test_time.rs index c321352d..dc307e57 100644 --- a/test/test_time.rs +++ b/test/test_time.rs @@ -6,11 +6,12 @@ target_os = "emscripten", ))] use nix::time::clock_getcpuclockid; -use nix::time::{clock_getres, clock_gettime, ClockId}; +use nix::time::{clock_gettime, ClockId}; +#[cfg(not(target_os = "redox"))] #[test] pub fn test_clock_getres() { - assert!(clock_getres(ClockId::CLOCK_REALTIME).is_ok()); + assert!(nix::time::clock_getres(ClockId::CLOCK_REALTIME).is_ok()); } #[test] @@ -31,6 +32,7 @@ pub fn test_clock_getcpuclockid() { assert!(clock_gettime(clock_id).is_ok()); } +#[cfg(not(target_os = "redox"))] #[test] pub fn test_clock_id_res() { assert!(ClockId::CLOCK_REALTIME.res().is_ok()); |