mirror of
https://github.com/fluencelabs/wasm-bindgen
synced 2025-03-16 02:00:51 +00:00
Merge pull request #928 from alexcrichton/node-args
Allow passing extra args to node in test runner
This commit is contained in:
commit
e368e49af1
@ -92,9 +92,16 @@ pub fn execute(
|
||||
let mut path = env::split_paths(&path).collect::<Vec<_>>();
|
||||
path.push(env::current_dir().unwrap());
|
||||
path.push(tmpdir.to_path_buf());
|
||||
let extra_node_args = env::var("NODE_ARGS")
|
||||
.unwrap_or_default()
|
||||
.split(",")
|
||||
.map(|s| s.to_string())
|
||||
.filter(|s| !s.is_empty())
|
||||
.collect::<Vec<_>>();
|
||||
exec(
|
||||
Command::new("node")
|
||||
.env("NODE_PATH", env::join_paths(&path).unwrap())
|
||||
.args(&extra_node_args)
|
||||
.arg(&js_path)
|
||||
.args(args),
|
||||
)
|
||||
|
Loading…
x
Reference in New Issue
Block a user