Skip to content

test: skip fs-copyfile-respect-permission if root - #27378

Closed
danbev wants to merge 2 commits into
nodejs:masterfrom
danbev:test-fs-copy-respect-permissions-root
Closed

test: skip fs-copyfile-respect-permission if root#27378
danbev wants to merge 2 commits into
nodejs:masterfrom
danbev:test-fs-copy-respect-permissions-root

Conversation

@danbev

Copy link
Copy Markdown
Contributor

Currently, if this test is run as the root user the following
failure will occur:

=== release test-fs-copyfile-respect-permissions ===Path: parallel/test-fs-copyfile-respect-permissionsassert.js:89 throw new AssertionError(obj); ^AssertionError [ERR_ASSERTION]: Missing expected exception (check). at Object.<anonymous> (/node/test/parallel/test-fs-copyfile-respect-permissions.js:38:10) at Module._compile (internal/modules/cjs/loader.js:759:30) at Object.Module._extensions..js (internal/modules/cjs/loader.js:770:10) at Module.load (internal/modules/cjs/loader.js:628:32) at Function.Module._load (internal/modules/cjs/loader.js:555:12) at Function.Module.runMain (internal/modules/cjs/loader.js:826:10) at internal/main/run_main_module.js:17:11Command:out/Release/node test/parallel/test-fs-copyfile-respect-permissions.js[05:41|% 100|+ 2620|- 1]: Done

This commit adds a root user check and skips this test if running as the
user root.

Checklist
  • make -j4 test (UNIX), or vcbuild test (Windows) passes
  • commit message follows commit guidelines

Currently, if this test is run as the root user the following
failure will occur:
=== release test-fs-copyfile-respect-permissions ===
Path: parallel/test-fs-copyfile-respect-permissions
assert.js:89
throw new AssertionError(obj);
^
AssertionError [ERR_ASSERTION]: Missing expected exception (check).
at Object.<anonymous>
(/node/test/parallel/test-fs-copyfile-respect-permissions.js:38:10)
at Module._compile (internal/modules/cjs/loader.js:759:30)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:770:10)
at Module.load (internal/modules/cjs/loader.js:628:32)
at Function.Module._load (internal/modules/cjs/loader.js:555:12)
at Function.Module.runMain (internal/modules/cjs/loader.js:826:10)
at internal/main/run_main_module.js:17:11
Command:
out/Release/node test/parallel/test-fs-copyfile-respect-permissions.js
[05:41|% 100|+ 2620|- 1]: Done
This commit adds a root user check and skips this test if running as the
user root.
@nodejs-github-bot

Copy link
Copy Markdown
Collaborator

@nodejs-github-botnodejs-github-bot added the test Issues and PRs related to the tests. label Apr 24, 2019
@nodejs-github-bot

Copy link
Copy Markdown
Collaborator

Comment threadtest/parallel/test-fs-copyfile-respect-permissions.js Outdated
@nodejs-github-bot

Copy link
Copy Markdown
Collaborator

@danbevdanbev added the author ready PRs that have at least one approval, no pending requests for changes, and a CI started. label Apr 24, 2019
@danbev

Copy link
Copy Markdown
ContributorAuthor

Landed in 2743645.

@danbevdanbev closed this Apr 29, 2019
@danbev
danbev deleted the test-fs-copy-respect-permissions-root branch April 29, 2019 03:41
danbev added a commit that referenced this pull request Apr 29, 2019
Currently, if this test is run as the root user the following
failure will occur:
=== release test-fs-copyfile-respect-permissions ===
Path: parallel/test-fs-copyfile-respect-permissions
assert.js:89
throw new AssertionError(obj);
^
AssertionError [ERR_ASSERTION]: Missing expected exception (check).
at Object.<anonymous>
(/node/test/parallel/test-fs-copyfile-respect-permissions.js:38:10)
at Module._compile (internal/modules/cjs/loader.js:759:30)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:770:10)
at Module.load (internal/modules/cjs/loader.js:628:32)
at Function.Module._load (internal/modules/cjs/loader.js:555:12)
at Function.Module.runMain (internal/modules/cjs/loader.js:826:10)
at internal/main/run_main_module.js:17:11
Command:
out/Release/node test/parallel/test-fs-copyfile-respect-permissions.js
[05:41|% 100|+ 2620|- 1]: Done
This commit adds a root user check and skips this test if running as the
user root.
PR-URL: #27378
Reviewed-By: Richard Lau <riclau@uk.ibm.com>
Reviewed-By: Rich Trott <rtrott@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Yongsheng Zhang <zyszys98@gmail.com>
targos pushed a commit that referenced this pull request Apr 29, 2019
Currently, if this test is run as the root user the following
failure will occur:
=== release test-fs-copyfile-respect-permissions ===
Path: parallel/test-fs-copyfile-respect-permissions
assert.js:89
throw new AssertionError(obj);
^
AssertionError [ERR_ASSERTION]: Missing expected exception (check).
at Object.<anonymous>
(/node/test/parallel/test-fs-copyfile-respect-permissions.js:38:10)
at Module._compile (internal/modules/cjs/loader.js:759:30)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:770:10)
at Module.load (internal/modules/cjs/loader.js:628:32)
at Function.Module._load (internal/modules/cjs/loader.js:555:12)
at Function.Module.runMain (internal/modules/cjs/loader.js:826:10)
at internal/main/run_main_module.js:17:11
Command:
out/Release/node test/parallel/test-fs-copyfile-respect-permissions.js
[05:41|% 100|+ 2620|- 1]: Done
This commit adds a root user check and skips this test if running as the
user root.
PR-URL: #27378
Reviewed-By: Richard Lau <riclau@uk.ibm.com>
Reviewed-By: Rich Trott <rtrott@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Yongsheng Zhang <zyszys98@gmail.com>
@targostargos mentioned this pull request May 6, 2019
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

author readyPRs that have at least one approval, no pending requests for changes, and a CI started.testIssues and PRs related to the tests.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

8 participants

@danbev@nodejs-github-bot@Trott@lpinca@cjihrig@richardlau@ZYSzys@mihalskiy