Files
bun.sh/bench/snippets/realpath.mjs
Michael H b54137174b Bench updates (#15029)
Co-authored-by: RiskyMH <RiskyMH@users.noreply.github.com>
2024-11-08 23:15:24 -08:00

11 lines
321 B
JavaScript

import { realpathSync } from "node:fs";
import { bench, run } from "../runner.mjs";
const count = parseInt(process.env.ITERATIONS || "1", 10) || 1;
const arg = process.argv[process.argv.length - 1];
bench("realpathSync x " + count, () => {
for (let i = 0; i < count; i++) realpathSync(arg, "utf-8");
});
await run();