summaryrefslogtreecommitdiff
path: root/testing/bench_example.ts
diff options
context:
space:
mode:
authorVincent LE GOFF <g_n_s@hotmail.fr>2019-04-24 13:41:23 +0200
committerRyan Dahl <ry@tinyclouds.org>2019-04-24 07:41:22 -0400
commitdcd01dd02530df0e799eb4227087680ffeb80d74 (patch)
tree8cc1dec75dd17c326fea6d7fe471b7e7a31032f7 /testing/bench_example.ts
parente1f7a60bb326f8299f339635c0738d28431afa0a (diff)
Eslint fixes (denoland/deno_std#356)
Make warnings fail Original: https://github.com/denoland/deno_std/commit/4543b563a9a01c8c168aafcbfd9d4634effba7fc
Diffstat (limited to 'testing/bench_example.ts')
-rw-r--r--testing/bench_example.ts6
1 files changed, 3 insertions, 3 deletions
diff --git a/testing/bench_example.ts b/testing/bench_example.ts
index 86e25b9a6..d27fb97e8 100644
--- a/testing/bench_example.ts
+++ b/testing/bench_example.ts
@@ -2,7 +2,7 @@
import { BenchmarkTimer, bench, runIfMain } from "./bench.ts";
// Basic
-bench(function forIncrementX1e9(b: BenchmarkTimer) {
+bench(function forIncrementX1e9(b: BenchmarkTimer): void {
b.start();
for (let i = 0; i < 1e9; i++);
b.stop();
@@ -12,7 +12,7 @@ bench(function forIncrementX1e9(b: BenchmarkTimer) {
bench({
name: "runs100ForIncrementX1e6",
runs: 100,
- func(b) {
+ func(b): void {
b.start();
for (let i = 0; i < 1e6; i++);
b.stop();
@@ -20,7 +20,7 @@ bench({
});
// Itsabug
-bench(function throwing(b) {
+bench(function throwing(b): void {
b.start();
// Throws bc the timer's stop method is never called
});