File tree Expand file tree Collapse file tree 3 files changed +24
-3
lines changed Expand file tree Collapse file tree 3 files changed +24
-3
lines changed Original file line number Diff line number Diff line change @@ -257,7 +257,7 @@ function extractGoResult(output: string): BenchmarkResult[] {
257257 // Example:
258258 // BenchmarkFib20-8 30000 41653 ns/op
259259 // BenchmarkDoWithConfigurer1-8 30000000 42.3 ns/op
260- const reExtract = / ^ ( B e n c h m a r k \w + ) ( - \d + ) ? \s + ( \d + ) \s + ( [ 0 - 9 . ] + ) \s + ( .+ ) $ / ;
260+ const reExtract = / ^ ( B e n c h m a r k \w + (?: \/ ? [ \w ( ) $ % ^ & * - ] * ? ) * ? ) ( - \d + ) ? \s + ( \d + ) \s + ( [ 0 - 9 . ] + ) \s + ( .+ ) $ / ;
261261
262262 for ( const line of lines ) {
263263 const m = line . match ( reExtract ) ;
Original file line number Diff line number Diff line change 11goos: darwin
22goarch: amd64
3- BenchmarkFib10-8 5000000 325 ns/op
4- BenchmarkFib20 30000 40537.123 ns/op
3+ BenchmarkFib10-8 5000000 325 ns/op
4+ BenchmarkFib20 30000 40537.123 ns/op
5+ BenchmarkFib/my_tabled_benchmark_-_10-8 5000000 325 ns/op
6+ BenchmarkFib/my_tabled_benchmark_-_20 30000 40537.123 ns/op
7+ BenchmarkFib/my/tabled/benchmark_-_20 30001 40537.456 ns/op
58PASS
69ok _/Users/rhayasd/Develop/github.com/benchmark-action/github-action-benchmark/examples/go 3.614s
Original file line number Diff line number Diff line change @@ -121,6 +121,24 @@ describe('extractResult()', function() {
121121 value : 40537.123 ,
122122 extra : '30000 times' ,
123123 } ,
124+ {
125+ name : 'BenchmarkFib/my_tabled_benchmark_-_10' ,
126+ unit : 'ns/op' ,
127+ value : 325 ,
128+ extra : '5000000 times\n8 procs' ,
129+ } ,
130+ {
131+ name : 'BenchmarkFib/my_tabled_benchmark_-_20' ,
132+ unit : 'ns/op' ,
133+ value : 40537.123 ,
134+ extra : '30000 times' ,
135+ } ,
136+ {
137+ name : 'BenchmarkFib/my/tabled/benchmark_-_20' ,
138+ unit : 'ns/op' ,
139+ value : 40537.456 ,
140+ extra : '30001 times' ,
141+ } ,
124142 ] ,
125143 } ,
126144 {
You can’t perform that action at this time.
0 commit comments