diff options
author | Artem Maksimov <temamaksimov@gmail.com> | 2019-11-06 13:23:27 +0300 |
---|---|---|
committer | Gireesh Punathil <gpunathi@in.ibm.com> | 2019-11-17 21:13:08 +0530 |
commit | 722f9588d7702dbe53a681dbbb5247a0ab0839c6 (patch) | |
tree | 330a47f6ec584b5d724ca534c0b94800dcc931fb | |
parent | 9bda2bb5b8cc2c87492203571179ae187c5840ce (diff) | |
download | android-node-v8-722f9588d7702dbe53a681dbbb5247a0ab0839c6.tar.gz android-node-v8-722f9588d7702dbe53a681dbbb5247a0ab0839c6.tar.bz2 android-node-v8-722f9588d7702dbe53a681dbbb5247a0ab0839c6.zip |
test: improve test-fs-open
If there is a file 'path' in the root dir, the test
will fail with the 'ENOTDIR' instead of 'ENOENT'.
Change path to something more unlikely.
PR-URL: https://github.com/nodejs/node/pull/30280
Reviewed-By: Сковорода Никита Андреевич <chalkerx@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com>
-rw-r--r-- | test/parallel/test-fs-open.js | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/test/parallel/test-fs-open.js b/test/parallel/test-fs-open.js index 51cd9ecf31..e33c4e9331 100644 --- a/test/parallel/test-fs-open.js +++ b/test/parallel/test-fs-open.js @@ -29,7 +29,7 @@ let caughtException = false; try { // Should throw ENOENT, not EBADF // see https://github.com/joyent/node/pull/1228 - fs.openSync('/path/to/file/that/does/not/exist', 'r'); + fs.openSync('/8hvftyuncxrt/path/to/file/that/does/not/exist', 'r'); } catch (e) { assert.strictEqual(e.code, 'ENOENT'); caughtException = true; |