summaryrefslogtreecommitdiff
path: root/cli/tests/testdata/bench/multiple_group.ts
diff options
context:
space:
mode:
authorRaashid Anwar <raashid12anwar@gmail.com>2023-12-18 04:27:14 +0530
committerGitHub <noreply@github.com>2023-12-17 22:57:14 +0000
commit9ede8d7b69c1d2859bb03e5bdffd7407042914ec (patch)
tree12776cfaab9387d2260cfe48d793a7010fd7c673 /cli/tests/testdata/bench/multiple_group.ts
parent4c2c053afeae3ba359ffc4b858877e69bae4c4dd (diff)
fix(bench): added group banner to bench output. (#21551)
Added group banner to bench output. --------- Co-authored-by: Bartek IwaƄczuk <biwanczuk@gmail.com>
Diffstat (limited to 'cli/tests/testdata/bench/multiple_group.ts')
-rw-r--r--cli/tests/testdata/bench/multiple_group.ts15
1 files changed, 15 insertions, 0 deletions
diff --git a/cli/tests/testdata/bench/multiple_group.ts b/cli/tests/testdata/bench/multiple_group.ts
new file mode 100644
index 000000000..69e73a7f2
--- /dev/null
+++ b/cli/tests/testdata/bench/multiple_group.ts
@@ -0,0 +1,15 @@
+Deno.bench("noop", { group: "noop" }, () => {});
+Deno.bench("noop2", { group: "noop", baseline: true }, () => {});
+
+Deno.bench("noop3", { group: "url" }, () => {});
+
+Deno.bench("parse url 2x", { group: "url", baseline: true }, () => {
+ new URL("https://deno.land/std/http/server.ts");
+ new URL("https://deno.land/std/http/server.ts");
+});
+
+Deno.bench("parse url 200x", { group: "url" }, () => {
+ for (let i = 0; i < 200; i++) {
+ new URL("https://deno.land/std/http/server.ts");
+ }
+});