diff options
author | Rich Trott <rtrott@gmail.com> | 2018-08-06 06:47:11 -0700 |
---|---|---|
committer | Rich Trott <rtrott@gmail.com> | 2018-08-08 09:17:44 -0700 |
commit | 41ae423718cb312c52c7b3bca1988130a2c417f6 (patch) | |
tree | 9882b9329f7a6c4ddd093702092ddea87523ea3f /test/parallel/test-fs-mkdir.js | |
parent | 6ad12d47f5cd0382c2011a3a1c3f0e8601c07f69 (diff) | |
download | android-node-v8-41ae423718cb312c52c7b3bca1988130a2c417f6.tar.gz android-node-v8-41ae423718cb312c52c7b3bca1988130a2c417f6.tar.bz2 android-node-v8-41ae423718cb312c52c7b3bca1988130a2c417f6.zip |
test: remove common.fileExists()
common.fileExists() can be replaced with fs.existsSync().
PR-URL: https://github.com/nodejs/node/pull/22151
Reviewed-By: Richard Lau <riclau@uk.ibm.com>
Reviewed-By: Weijia Wang <starkwang@126.com>
Reviewed-By: Jon Moss <me@jonathanmoss.me>
Reviewed-By: Michaël Zasso <targos@protonmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Сковорода Никита Андреевич <chalkerx@gmail.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com>
Reviewed-By: Tobias Nießen <tniessen@tnie.de>
Reviewed-By: Franziska Hinkelmann <franziska.hinkelmann@gmail.com>
Diffstat (limited to 'test/parallel/test-fs-mkdir.js')
-rw-r--r-- | test/parallel/test-fs-mkdir.js | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/test/parallel/test-fs-mkdir.js b/test/parallel/test-fs-mkdir.js index 937c73aca4..18e9e973f1 100644 --- a/test/parallel/test-fs-mkdir.js +++ b/test/parallel/test-fs-mkdir.js @@ -32,7 +32,7 @@ tmpdir.refresh(); fs.mkdir(pathname, common.mustCall(function(err) { assert.strictEqual(err, null); - assert.strictEqual(common.fileExists(pathname), true); + assert.strictEqual(fs.existsSync(pathname), true); })); } @@ -41,7 +41,7 @@ tmpdir.refresh(); fs.mkdir(pathname, 0o777, common.mustCall(function(err) { assert.strictEqual(err, null); - assert.strictEqual(common.fileExists(pathname), true); + assert.strictEqual(fs.existsSync(pathname), true); })); } @@ -50,7 +50,7 @@ tmpdir.refresh(); fs.mkdirSync(pathname); - const exists = common.fileExists(pathname); + const exists = fs.existsSync(pathname); assert.strictEqual(exists, true); } |