summaryrefslogtreecommitdiff
path: root/test/v8-updates
diff options
context:
space:
mode:
authorMichaël Zasso <targos@protonmail.com>2021-05-18 19:04:20 +0200
committerMichaël Zasso <targos@protonmail.com>2021-06-10 11:11:50 +0200
commitce4b4cc0aff75cc91dc9cf61b09aedc5fbb061c3 (patch)
tree1fd9ff5b7d57993112cfc0468f234d3849f087de /test/v8-updates
parentf691deef261bf20900537dd028a60d991f80ebfe (diff)
downloadnode-new-ce4b4cc0aff75cc91dc9cf61b09aedc5fbb061c3.tar.gz
test: adapt test-linux-perf to V8 changes
Refs: https://github.com/v8/v8/commit/9a31804bbe6597bfb54b47958fd3839f2da51875 PR-URL: https://github.com/nodejs/node/pull/38273 Reviewed-By: Jiawen Geng <technicalcute@gmail.com> Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com> Reviewed-By: Michael Dawson <midawson@redhat.com> Reviewed-By: Mary Marchini <oss@mmarchini.me>
Diffstat (limited to 'test/v8-updates')
-rw-r--r--test/v8-updates/test-linux-perf.js19
1 files changed, 11 insertions, 8 deletions
diff --git a/test/v8-updates/test-linux-perf.js b/test/v8-updates/test-linux-perf.js
index 9a8097b071..58388d37ce 100644
--- a/test/v8-updates/test-linux-perf.js
+++ b/test/v8-updates/test-linux-perf.js
@@ -96,17 +96,20 @@ for (const perfArgs of perfArgsList) {
output += perfScript.stdout;
}
-const interpretedFunctionOneRe = /InterpretedFunction:functionOne/;
-const compiledFunctionOneRe = /LazyCompile:\*functionOne/;
-const interpretedFunctionTwoRe = /InterpretedFunction:functionTwo/;
-const compiledFunctionTwoRe = /LazyCompile:\*functionTwo/;
+const interpretedFunctionOneRe = /~functionOne/;
+const compiledFunctionOneRe = /\*functionOne/;
+const interpretedFunctionTwoRe = /~functionTwo/;
+const compiledFunctionTwoRe = /\*functionTwo/;
+function makeAssertMessage(message) {
+ return message + '\nPerf output:\n\n' + output;
+}
assert.ok(output.match(interpretedFunctionOneRe),
- "Couldn't find interpreted functionOne()");
+ makeAssertMessage("Couldn't find interpreted functionOne()"));
assert.ok(output.match(compiledFunctionOneRe),
- "Couldn't find compiled functionOne()");
+ makeAssertMessage("Couldn't find compiled functionOne()"));
assert.ok(output.match(interpretedFunctionTwoRe),
- "Couldn't find interpreted functionTwo()");
+ makeAssertMessage("Couldn't find interpreted functionTwo()"));
assert.ok(output.match(compiledFunctionTwoRe),
- "Couldn't find compiled functionTwo");
+ makeAssertMessage("Couldn't find compiled functionTwo"));