diff options
Diffstat (limited to 'cli/tests')
-rw-r--r-- | cli/tests/integration/bench_tests.rs | 6 | ||||
-rw-r--r-- | cli/tests/testdata/bench/pass.json.out | 28 |
2 files changed, 34 insertions, 0 deletions
diff --git a/cli/tests/integration/bench_tests.rs b/cli/tests/integration/bench_tests.rs index 7953bef34..15a86ee9d 100644 --- a/cli/tests/integration/bench_tests.rs +++ b/cli/tests/integration/bench_tests.rs @@ -178,6 +178,12 @@ itest!(bench_with_malformed_config { output: "bench/collect_with_malformed_config.out", }); +itest!(json_output { + args: "bench --json bench/pass.ts", + exit_code: 0, + output: "bench/pass.json.out", +}); + #[test] fn recursive_permissions_pledge() { let output = util::deno_cmd() diff --git a/cli/tests/testdata/bench/pass.json.out b/cli/tests/testdata/bench/pass.json.out new file mode 100644 index 000000000..73daa7202 --- /dev/null +++ b/cli/tests/testdata/bench/pass.json.out @@ -0,0 +1,28 @@ +Check file:///[WILDCARD]testdata/bench/pass.ts +{ + "runtime": "Deno/[WILDCARD]", + "cpu": "[WILDCARD]", + "benches": [ + { + "origin": "file:///[WILDCARD]testdata/bench/pass.ts", + "group": null, + "name": "bench0", + "baseline": false, + "results": [ + { + "ok": { + "n": [WILDCARD], + "min": [WILDCARD], + "max": [WILDCARD], + "avg": [WILDCARD], + "p75": [WILDCARD], + "p99": [WILDCARD], + "p995": [WILDCARD], + "p999": [WILDCARD] + } + } + ] + }, +[WILDCARD] + ] +} |