test: fix child-process-uid-gid on Windows
The process.getuid method does not exist on this platform. Ref: https://github.com/nodejs/node/pull/8864 PR-URL: https://github.com/nodejs/node/pull/8924 Reviewed-By: Luigi Pinca <luigipinca@gmail.com> Reviewed-By: Wyatt Preul <wpreul@gmail.com> Reviewed-By: Rich Trott <rtrott@gmail.com> Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
This commit is contained in:
parent
d097311a1b
commit
1554735dec
@ -3,7 +3,7 @@ const common = require('../common');
|
|||||||
const assert = require('assert');
|
const assert = require('assert');
|
||||||
const spawn = require('child_process').spawn;
|
const spawn = require('child_process').spawn;
|
||||||
|
|
||||||
if (process.getuid() === 0) {
|
if (!common.isWindows && process.getuid() === 0) {
|
||||||
common.skip('as this test should not be run as `root`');
|
common.skip('as this test should not be run as `root`');
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user