Skip to content

test: replace with template literals #14293

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 3 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion test/inspector/inspector-helper.js
Original file line number Diff line number Diff line change
Expand Up @@ -393,7 +393,7 @@ Harness.prototype.addStderrFilter = function(regexp, callback) {

Harness.prototype.assertStillAlive = function() {
assert.strictEqual(this.running_, true,
'Child died: ' + JSON.stringify(this.result_));
`Child died: ${JSON.stringify(this.result_)}`);
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm usually the last one to worry about that sort of stuff - but is it possible this terminology is offensive? If we swapped out other trigger references I think it would be nice to have a code base without dead children.

It's entirely appropriate in terms of my culture and language background - but I want to check how others feel about it. If someone feels strongly - will open an issue.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

As a not native speaker, I think this can be disturbing.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Lexically this has reasonable affinity with #13684, so makes sense to change the wordings, though through another PR - as the objective of this one is to introduce template strings and is met.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Let's just make it Child exited ${JSON.stringify(this.result_)}

};

Harness.prototype.run_ = function() {
Expand Down
4 changes: 2 additions & 2 deletions test/parallel/test-https-server-keep-alive-timeout.js
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,8 @@ const fs = require('fs');
const tests = [];

const serverOptions = {
key: fs.readFileSync(common.fixturesDir + '/keys/agent1-key.pem'),
cert: fs.readFileSync(common.fixturesDir + '/keys/agent1-cert.pem')
key: fs.readFileSync(`${common.fixturesDir}/keys/agent1-key.pem`),
cert: fs.readFileSync(`${common.fixturesDir}/keys/agent1-cert.pem`)
};

function test(fn) {
Expand Down
2 changes: 1 addition & 1 deletion test/sequential/test-debugger-debug-brk.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ common.skipIfInspectorDisabled();
const assert = require('assert');
const spawn = require('child_process').spawn;

const script = common.fixturesDir + '/empty.js';
const script = `${common.fixturesDir}/empty.js`;

function test(arg) {
const child = spawn(process.execPath, ['--inspect', arg, script]);
Expand Down