summaryrefslogtreecommitdiff
path: root/test/async-hooks/verify-graph.js
diff options
context:
space:
mode:
authorweiyuanyue <millywey@qq.com>2017-07-16 15:28:44 +0800
committerRich Trott <rtrott@gmail.com>2017-07-17 05:41:34 -0700
commitfc711314f18339c2f6f019c32ff9660048da9c13 (patch)
treebba0f8f84f3723c27c52cb548b71795c1d9d8bf2 /test/async-hooks/verify-graph.js
parent0aae941dbe0acf7c2bc920f563631bc20e5c075f (diff)
downloadandroid-node-v8-fc711314f18339c2f6f019c32ff9660048da9c13.tar.gz
android-node-v8-fc711314f18339c2f6f019c32ff9660048da9c13.tar.bz2
android-node-v8-fc711314f18339c2f6f019c32ff9660048da9c13.zip
test: replace string concatenation with template
Replace string concatenation with template literals in test/async-hooks/verify-graph.js. PR-URL: https://github.com/nodejs/node/pull/14279 Reviewed-By: Rich Trott <rtrott@gmail.com> Reviewed-By: Gibson Fahnestock <gibfahn@gmail.com> Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: Timothy Gu <timothygu99@gmail.com> Reviewed-By: Tobias Nießen <tniessen@tnie.de> Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com> Reviewed-By: Refael Ackermann <refack@gmail.com>
Diffstat (limited to 'test/async-hooks/verify-graph.js')
-rw-r--r--test/async-hooks/verify-graph.js2
1 files changed, 1 insertions, 1 deletions
diff --git a/test/async-hooks/verify-graph.js b/test/async-hooks/verify-graph.js
index 5e8795ef97..451550d33f 100644
--- a/test/async-hooks/verify-graph.js
+++ b/test/async-hooks/verify-graph.js
@@ -106,7 +106,7 @@ module.exports.printGraph = function printGraph(hooks) {
function procesNode(x) {
const key = x.type.replace(/WRAP/, '').toLowerCase();
if (!ids[key]) ids[key] = 1;
- const id = key + ':' + ids[key]++;
+ const id = `${key}:${ids[key]++}`;
uidtoid[x.uid] = id;
const triggerAsyncId = uidtoid[x.triggerAsyncId] || null;
graph.push({ type: x.type, id, triggerAsyncId });