diff options
author | buji <zheyuzhang03@gmail.com> | 2017-11-20 09:04:28 +0800 |
---|---|---|
committer | James M Snell <jasnell@gmail.com> | 2017-11-22 08:40:34 -0800 |
commit | b28a28a55ab7324ac35eaee4b8b84ecdd88a3dce (patch) | |
tree | bc97d5902b36b785c24f5b08fce59baea727939f | |
parent | fdbee334cd03ed7e62d4e621578a277362512813 (diff) | |
download | android-node-v8-b28a28a55ab7324ac35eaee4b8b84ecdd88a3dce.tar.gz android-node-v8-b28a28a55ab7324ac35eaee4b8b84ecdd88a3dce.tar.bz2 android-node-v8-b28a28a55ab7324ac35eaee4b8b84ecdd88a3dce.zip |
test: remove unlink function which is needless
PR-URL: https://github.com/nodejs/node/pull/17119
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Rich Trott <rtrott@gmail.com>
Reviewed-By: Daniel Bevenius <daniel.bevenius@gmail.com>
-rw-r--r-- | test/parallel/test-fs-mkdir.js | 18 |
1 files changed, 0 insertions, 18 deletions
diff --git a/test/parallel/test-fs-mkdir.js b/test/parallel/test-fs-mkdir.js index 21f8774e69..54585a3f12 100644 --- a/test/parallel/test-fs-mkdir.js +++ b/test/parallel/test-fs-mkdir.js @@ -24,13 +24,6 @@ const common = require('../common'); const assert = require('assert'); const fs = require('fs'); -function unlink(pathname) { - try { - fs.rmdirSync(pathname); - } catch (e) { - } -} - common.refreshTmpDir(); { @@ -40,10 +33,6 @@ common.refreshTmpDir(); assert.strictEqual(err, null); assert.strictEqual(common.fileExists(pathname), true); })); - - process.on('exit', function() { - unlink(pathname); - }); } { @@ -53,21 +42,14 @@ common.refreshTmpDir(); assert.strictEqual(err, null); assert.strictEqual(common.fileExists(pathname), true); })); - - process.on('exit', function() { - unlink(pathname); - }); } { const pathname = `${common.tmpDir}/test3`; - unlink(pathname); fs.mkdirSync(pathname); const exists = common.fileExists(pathname); - unlink(pathname); - assert.strictEqual(exists, true); } |