({ n, type, inputType })
| 64 | }); |
| 65 | |
| 66 | function main({ n, type, inputType }) { |
| 67 | const inputs = paramGenerator(inputType); |
| 68 | const input = inputs[type]; |
| 69 | |
| 70 | // Force optimization before starting the benchmark |
| 71 | for (const name in inputs) { |
| 72 | new URLSearchParams(inputs[name]); |
| 73 | } |
| 74 | |
| 75 | bench.start(); |
| 76 | for (let i = 0; i < n; i += 1) |
| 77 | new URLSearchParams(input); |
| 78 | bench.end(n); |
| 79 | } |
nothing calls this directly
no test coverage detected
searching dependent graphs…