Permalink
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Browse files
test,v8: skip less and stabilize test-linux-perf.js
Co-authored-by: Matheus Marchini <mat@mmarchini.me> PR-URL: #27364 Refs: nodejs/build#1774 Reviewed-By: Matheus Marchini <mat@mmarchini.me> Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
- Loading branch information
Showing
with
61 additions
and 39 deletions.
- +9 −18 test/fixtures/linux-perf.js
- +52 −21 test/v8-updates/test-linux-perf.js
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| @@ -1,26 +1,17 @@ | ||
| 'use strict'; | ||
|
|
||
| const { spawnSync } = require("child_process"); | ||
| const sleepTime = new Number(process.argv[2] || "0.1"); | ||
| const repeat = new Number(process.argv[3]) || 5; | ||
|
|
||
| function functionOne() { | ||
| functionTwo(); | ||
| } | ||
|
|
||
| function functionTwo() { | ||
| spawnSync('sleep', [`${sleepTime}`]); | ||
| } | ||
|
|
||
| for (let i = 0; i < repeat; i++) { | ||
| functionOne(); | ||
| } |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters