We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 76b27ae commit 295dfefCopy full SHA for 295dfef
test/test_spawn.rs
@@ -1,11 +1,13 @@
1
-use std::ffi::CString;
2
-
+use super::FORK_MTX;
3
use nix::spawn::{self, PosixSpawnAttr, PosixSpawnFileActions};
4
use nix::sys::signal;
5
use nix::sys::wait::{waitpid, WaitPidFlag, WaitStatus};
+use std::ffi::CString;
6
7
#[test]
8
fn spawn_true() {
9
+ let _guard = FORK_MTX.lock();
10
+
11
let bin = &CString::new("true").unwrap();
12
let args = &[
13
CString::new("true").unwrap(),
@@ -32,6 +34,8 @@ fn spawn_true() {
32
34
33
35
36
fn spawn_sleep() {
37
38
39
let bin = &CString::new("sleep").unwrap();
40
let args = &[CString::new("sleep").unwrap(), CString::new("30").unwrap()];
41
let vars: &[CString] = &[];
0 commit comments