Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit 8f550df

Browse filesBrowse files
Johnny Readingaddaleax
authored andcommitted
test: refactor child-process-spawn-error
Use const instead of var for assignments. PR-URL: #9951 Reviewed-By: Prince John Wesley <princejohnwesley@gmail.com> Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
1 parent b73f6b7 commit 8f550df
Copy full SHA for 8f550df

File tree

Expand file treeCollapse file tree

1 file changed

+6
-6
lines changed
Open diff view settings
Filter options
Expand file treeCollapse file tree

1 file changed

+6
-6
lines changed
Open diff view settings
Collapse file

‎test/parallel/test-child-process-spawn-error.js‎

Copy file name to clipboardExpand all lines: test/parallel/test-child-process-spawn-error.js
+6-6Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,13 @@
11
'use strict';
2-
var common = require('../common');
3-
var spawn = require('child_process').spawn;
4-
var assert = require('assert');
2+
const common = require('../common');
3+
const spawn = require('child_process').spawn;
4+
const assert = require('assert');
55

6-
var enoentPath = 'foo123';
7-
var spawnargs = ['bar'];
6+
const enoentPath = 'foo123';
7+
const spawnargs = ['bar'];
88
assert.strictEqual(common.fileExists(enoentPath), false);
99

10-
var enoentChild = spawn(enoentPath, spawnargs);
10+
const enoentChild = spawn(enoentPath, spawnargs);
1111
enoentChild.on('error', common.mustCall(function(err) {
1212
assert.strictEqual(err.code, 'ENOENT');
1313
assert.strictEqual(err.errno, 'ENOENT');

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.