summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRich Trott <rtrott@gmail.com>2017-05-18 20:03:44 -0700
committerJames M Snell <jasnell@gmail.com>2017-05-23 11:39:10 -0700
commit1af8b70c57f51755ecd211997f24d7266365c1ff (patch)
tree6d284ba285e7c4fbafeb4add314a6efdef476564
parent72429b39811cc8e981aeda03be254121bef81fb9 (diff)
downloadnode-new-1af8b70c57f51755ecd211997f24d7266365c1ff.tar.gz
test: allow for absent nobody user in setuid test
Some isolated build or test VMs don't have a "nobody" user, causing the parallel/test-process-setuid-setgid test to fail. Add logic to allow for that situation. PR-URL: https://github.com/nodejs/node/pull/13112 Fixes: https://github.com/nodejs/node/issues/13071 Reviewed-By: Gibson Fahnestock <gibfahn@gmail.com> Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
-rw-r--r--test/parallel/test-process-setuid-setgid.js2
1 files changed, 1 insertions, 1 deletions
diff --git a/test/parallel/test-process-setuid-setgid.js b/test/parallel/test-process-setuid-setgid.js
index 38a677970c..1feb4248d1 100644
--- a/test/parallel/test-process-setuid-setgid.js
+++ b/test/parallel/test-process-setuid-setgid.js
@@ -51,7 +51,7 @@ if (process.getuid() !== 0) {
assert.throws(
() => { process.setuid('nobody'); },
- /^Error: EPERM, /
+ /^Error: (EPERM, .+|setuid user id does not exist)$/
);
return;
}