summaryrefslogtreecommitdiff
path: root/test/parallel/test-fs-realpath-buffer-encoding.js
diff options
context:
space:
mode:
Diffstat (limited to 'test/parallel/test-fs-realpath-buffer-encoding.js')
-rw-r--r--test/parallel/test-fs-realpath-buffer-encoding.js5
1 files changed, 3 insertions, 2 deletions
diff --git a/test/parallel/test-fs-realpath-buffer-encoding.js b/test/parallel/test-fs-realpath-buffer-encoding.js
index fd7b0d5c3d..0ce6ec576d 100644
--- a/test/parallel/test-fs-realpath-buffer-encoding.js
+++ b/test/parallel/test-fs-realpath-buffer-encoding.js
@@ -8,14 +8,15 @@ const buffer_dir = Buffer.from(string_dir);
const encodings = ['ascii', 'utf8', 'utf16le', 'ucs2',
'base64', 'binary', 'hex'];
-var expected = {};
+const expected = {};
encodings.forEach((encoding) => {
expected[encoding] = buffer_dir.toString(encoding);
});
// test sync version
-for (var encoding in expected) {
+let encoding;
+for (encoding in expected) {
const expected_value = expected[encoding];
let result;