Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
return (log?: (...args: unknown[]) => void) => {
log = log ?? (() => {});
log('Creating %s, %d', name, count);
let start = process.hrtime();
const table = new RoutingTable(router);
table.registerController(spec, TestController);
router.list(); // Force sorting
log('Created %s %s', name, process.hrtime(start));
log('Starting %s %d', name, count);
let found = 0,
missed = 0;
start = process.hrtime();
for (let i = 0; i < count; i++) {
let group = `group${i}`;
if (i % 8 === 0) {
// Make it not found
group = 'groupX';
}
// eslint-disable-next-line @typescript-eslint/no-explicit-any
const request: any = {