Browse Source

test: replace string concatenation with template

PR-URL: https://github.com/nodejs/node/pull/15915
Reviewed-By: Daijiro Wachi <daijiro.wachi@gmail.com>
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Tobias Nießen <tniessen@tnie.de>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
v9.x-staging
Rob Paton 7 years ago
committed by Ruben Bridgewater
parent
commit
66a990b5ed
No known key found for this signature in database GPG Key ID: F07496B3EB3C1762
  1. 5
      test/parallel/test-http-incoming-pipelined-socket-destroy.js

5
test/parallel/test-http-incoming-pipelined-socket-destroy.js

@ -60,9 +60,10 @@ const server = http.createServer(common.mustCall(function(req, res) {
// Make a bunch of requests pipelined on the same socket // Make a bunch of requests pipelined on the same socket
function generator(seeds) { function generator(seeds) {
const port = server.address().port;
return seeds.map(function(r) { return seeds.map(function(r) {
return 'GET /' + r + ' HTTP/1.1\r\n' + return `GET /${r} HTTP/1.1\r\n` +
`Host: localhost:${server.address().port}\r\n` + `Host: localhost:${port}\r\n` +
'\r\n' + '\r\n' +
'\r\n'; '\r\n';
}).join(''); }).join('');

Loading…
Cancel
Save