summaryrefslogtreecommitdiff
path: root/testing/bench.ts
diff options
context:
space:
mode:
authorVincent LE GOFF <g_n_s@hotmail.fr>2019-05-10 16:48:06 +0200
committerRyan Dahl <ry@tinyclouds.org>2019-05-10 10:48:06 -0400
commite56c207f2c27ef5f919de37e6fb269dfbb12f38e (patch)
tree3281be3156559f0656095da7ed914d337551c0f2 /testing/bench.ts
parent480b9e71ff5b377681341b2f28b6f36a44268172 (diff)
benching: use performance.now (denoland/deno_std#385)
Original: https://github.com/denoland/deno_std/commit/ad1b95eaf75d0e65367f3ad956a691e9348a2dc5
Diffstat (limited to 'testing/bench.ts')
-rw-r--r--testing/bench.ts4
1 files changed, 2 insertions, 2 deletions
diff --git a/testing/bench.ts b/testing/bench.ts
index 5b396df0e..3bb62526d 100644
--- a/testing/bench.ts
+++ b/testing/bench.ts
@@ -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();
}
};
}