Skip to content

Commit

Permalink
Fix ID mapping test on macOS
Browse files Browse the repository at this point in the history
  • Loading branch information
cd-work committed Sep 27, 2023
1 parent 3a51640 commit ee74838
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions tests/consistent_id_mappings.rs
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
#[cfg(target_os = "linux")]
use birdcage::{Birdcage, Sandbox};

#[cfg(target_os = "linux")]
fn main() {
let uid = unsafe { libc::getuid() };
let gid = unsafe { libc::getgid() };
Expand All @@ -14,3 +16,6 @@ fn main() {
assert_eq!(euid, unsafe { libc::geteuid() });
assert_eq!(egid, unsafe { libc::getegid() });
}

#[cfg(not(target_os = "linux"))]
fn main() {}

0 comments on commit ee74838

Please sign in to comment.