diff options
author | jy95 <jacques.yakoub@gmail.com> | 2018-09-22 21:13:42 +0200 |
---|---|---|
committer | Rich Trott <rtrott@gmail.com> | 2018-12-04 07:48:00 -0800 |
commit | 841caef9db88347e5c61668a814ccd5b99fc00a1 (patch) | |
tree | b66a2ed87157a3bd46490bc18425d8d6aadb5b09 /test/parallel/test-fs-open-mode-mask.js | |
parent | 9e12409ec30d9eae0a696ada911e2925922123cc (diff) | |
download | android-node-v8-841caef9db88347e5c61668a814ccd5b99fc00a1.tar.gz android-node-v8-841caef9db88347e5c61668a814ccd5b99fc00a1.tar.bz2 android-node-v8-841caef9db88347e5c61668a814ccd5b99fc00a1.zip |
test: use ES2017 syntax in test-fs-open-*
Update test-fs-open-flags to take advantage of destructuring and default
values.
Update test-fs-open-mode-mask to use a ternary to make use of a
constant possible.
PR-URL: https://github.com/nodejs/node/pull/23031
Reviewed-By: Rich Trott <rtrott@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Diffstat (limited to 'test/parallel/test-fs-open-mode-mask.js')
-rw-r--r-- | test/parallel/test-fs-open-mode-mask.js | 8 |
1 files changed, 1 insertions, 7 deletions
diff --git a/test/parallel/test-fs-open-mode-mask.js b/test/parallel/test-fs-open-mode-mask.js index 0cd9a2c592..4100fbb32c 100644 --- a/test/parallel/test-fs-open-mode-mask.js +++ b/test/parallel/test-fs-open-mode-mask.js @@ -7,13 +7,7 @@ const assert = require('assert'); const path = require('path'); const fs = require('fs'); -let mode; - -if (common.isWindows) { - mode = 0o444; -} else { - mode = 0o644; -} +const mode = common.isWindows ? 0o444 : 0o644; const maskToIgnore = 0o10000; |