@@ -44,9 +44,9 @@ const testCases = [
4444 title : '--perf-basic-prof interpreted' ,
4545 nodeFlags : [ '--perf-basic-prof' , '--no-turbo-inlining' , '--no-opt' ] ,
4646 matches : [
47- '~functionOne .+/linux-perf-logger.js' ,
48- '~functionTwo .+/linux-perf-logger.js' ,
49- 'test-regex' ,
47+ 'JS: ~functionOne .+/linux-perf-logger.js' ,
48+ 'JS: ~functionTwo .+/linux-perf-logger.js' ,
49+ "RegExp\\.> src: 'test-regex' flags: 'gi'" ,
5050 ] ,
5151 noMatches : [ '\\*functionOne' , '\\*functionTwo' ] ,
5252 } ,
@@ -55,29 +55,32 @@ const testCases = [
5555 nodeFlags : [ '--perf-basic-prof' , '--no-turbo-inlining' , '--always-turbofan' ,
5656 '--minimum-invocations-before-optimization=0' ] ,
5757 matches : [
58- 'test-regex' ,
59- '~functionOne .+/linux-perf-logger.js' ,
60- '~functionTwo .+/linux-perf-logger.js' ,
61- '\\*functionOne .+/linux-perf-logger.js' ,
62- '\\*functionTwo .+/linux-perf-logger.js' ,
58+ "RegExp\\.> src: 'test-regex' flags: 'gi'" ,
59+ 'JS: ~functionOne .+/linux-perf-logger.js' ,
60+ 'JS: ~functionTwo .+/linux-perf-logger.js' ,
61+ 'JS: \\*functionOne .+/linux-perf-logger.js' ,
62+ 'JS: \\*functionTwo .+/linux-perf-logger.js' ,
6363 ] ,
6464 noMatches : [ ] ,
6565 } ,
6666 {
6767 title : '--perf-basic-prof-only-functions interpreted' ,
6868 nodeFlags : [ '--perf-basic-prof-only-functions' , '--no-turbo-inlining' , '--no-opt' ] ,
69- matches : [ '~functionOne .+/linux-perf-logger.js' , '~functionTwo .+/linux-perf-logger.js' ] ,
69+ matches : [
70+ 'JS:~functionOne .+/linux-perf-logger.js' ,
71+ '~functionTwo .+/linux-perf-logger.js' ,
72+ ] ,
7073 noMatches : [ '\\*functionOne' , '\\*functionTwo' , 'test-regex' ] ,
7174 } ,
7275 {
7376 title : '--perf-basic-prof-only-functions compiled' ,
7477 nodeFlags : [ '--perf-basic-prof-only-functions' , '--no-turbo-inlining' , '--always-turbofan' ,
7578 '--minimum-invocations-before-optimization=0' ] ,
7679 matches : [
77- '~functionOne .+/linux-perf-logger.js' ,
78- '~functionTwo .+/linux-perf-logger.js' ,
79- '\\*functionOne .+/linux-perf-logger.js' ,
80- '\\*functionTwo .+/linux-perf-logger.js' ,
80+ 'JS: ~functionOne .+/linux-perf-logger.js' ,
81+ 'JS: ~functionTwo .+/linux-perf-logger.js' ,
82+ 'JS: \\*functionOne .+/linux-perf-logger.js' ,
83+ 'JS: \\*functionTwo .+/linux-perf-logger.js' ,
8184 ] ,
8285 noMatches : [ 'test-regex' ] ,
8386 } ,
@@ -110,7 +113,7 @@ function runTest(test) {
110113
111114 const hexRegex = '[a-fA-F0-9]+' ;
112115 for ( const testRegex of test . matches ) {
113- const lineRegex = new RegExp ( `${ hexRegex } ${ hexRegex } .*: ${ testRegex } ` ) ;
116+ const lineRegex = new RegExp ( `${ hexRegex } ${ hexRegex } .* ${ testRegex } ` ) ;
114117 if ( ! lineRegex . test ( report . perfMap ) ) {
115118 report . errors . push ( `Expected to match ${ lineRegex } ` ) ;
116119 }
0 commit comments