1
0
Fork 0
mirror of https://github.com/denoland/deno.git synced 2025-01-12 17:09:00 -05:00

benching: use performance.now (#385)

This commit is contained in:
Vincent LE GOFF 2019-05-10 16:48:06 +02:00 committed by Ryan Dahl
parent 8714252916
commit ad1b95eaf7

View file

@ -61,10 +61,10 @@ function assertTiming(clock: BenchmarkClock): void {
function createBenchmarkTimer(clock: BenchmarkClock): BenchmarkTimer {
return {
start(): void {
clock.start = Date.now();
clock.start = performance.now();
},
stop(): void {
clock.stop = Date.now();
clock.stop = performance.now();
}
};
}