summaryrefslogtreecommitdiff
path: root/benching/mod.ts
diff options
context:
space:
mode:
authorVincent LE GOFF <g_n_s@hotmail.fr>2019-03-04 17:02:49 +0100
committerRyan Dahl <ry@tinyclouds.org>2019-03-04 11:02:49 -0500
commit87d044ec2405c2ff5bd18e9b7876156283a3d5ff (patch)
tree457da082781ce3f5d48a324cb108acc41c41ee94 /benching/mod.ts
parente3a0c6f15f6bf2c0b2c061ab2395866ecfb57576 (diff)
Fixing default parameters of runBenchmarks (denoland/deno_std#229)
Original: https://github.com/denoland/deno_std/commit/facc8ce9d228148353c407869a32cc4295b9a264
Diffstat (limited to 'benching/mod.ts')
-rw-r--r--benching/mod.ts4
1 files changed, 2 insertions, 2 deletions
diff --git a/benching/mod.ts b/benching/mod.ts
index 61df5c06b..4d2f5d41e 100644
--- a/benching/mod.ts
+++ b/benching/mod.ts
@@ -91,9 +91,9 @@ export function bench(
/** Runs all registered and non-skipped benchmarks serially. */
export async function runBenchmarks({
- only = /[^\s]+/,
+ only = /[^\s]/,
skip = /^\s*$/
-}: BenchmarkRunOptions): Promise<void> {
+}: BenchmarkRunOptions = {}): Promise<void> {
// Filtering candidates by the "only" and "skip" constraint
const benchmarks: Array<BenchmarkDefinition> = candidates.filter(
({ name }) => only.test(name) && !skip.test(name)