mirror of
https://github.com/denoland/deno.git
synced 2025-01-21 13:00:36 -05:00
chore: deprecate bench tests
This commit is contained in:
parent
e6869d7fa6
commit
78644388fa
4 changed files with 19 additions and 15 deletions
|
@ -1,7 +1,6 @@
|
|||
// Copyright 2018-2024 the Deno authors. All rights reserved. MIT license.
|
||||
|
||||
use deno_core::serde_json::json;
|
||||
use deno_core::url::Url;
|
||||
use test_util as util;
|
||||
use util::assert_contains;
|
||||
use util::assert_not_contains;
|
||||
|
@ -22,20 +21,6 @@ fn recursive_permissions_pledge() {
|
|||
);
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn file_protocol() {
|
||||
let file_url =
|
||||
Url::from_file_path(util::testdata_path().join("bench/file_protocol.ts"))
|
||||
.unwrap()
|
||||
.to_string();
|
||||
let context = TestContext::default();
|
||||
context
|
||||
.new_command()
|
||||
.args(format!("bench bench/file_protocol.ts {file_url}"))
|
||||
.run()
|
||||
.assert_matches_file("bench/file_protocol.out");
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn conditionally_loads_type_graph() {
|
||||
let context = TestContext::default();
|
||||
|
|
8
tests/specs/bench/file_protocol/__test__.jsonc
Normal file
8
tests/specs/bench/file_protocol/__test__.jsonc
Normal file
|
@ -0,0 +1,8 @@
|
|||
{
|
||||
"args": [
|
||||
"bench",
|
||||
"file_protocol.ts"
|
||||
],
|
||||
"output": "file_protocol.out",
|
||||
"exitCode": 0
|
||||
}
|
10
tests/specs/bench/file_protocol/file_protocol.out
Normal file
10
tests/specs/bench/file_protocol/file_protocol.out
Normal file
|
@ -0,0 +1,10 @@
|
|||
Check file://[WILDCARD]/file_protocol.ts
|
||||
CPU | [WILDCARD]
|
||||
Runtime | Deno [WILDCARD] ([WILDCARD])
|
||||
|
||||
[WILDCARD]/file_protocol.ts
|
||||
|
||||
benchmark time/iter (avg) iter/s (min … max) p75 p99 p995
|
||||
----------- ----------------------------- --------------------- --------------------------
|
||||
bench0 [WILDCARD] [WILDCARD] [WILDCARD] ([WILDCARD] … [WILDCARD]) [WILDCARD]
|
||||
|
1
tests/specs/bench/file_protocol/file_protocol.ts
Normal file
1
tests/specs/bench/file_protocol/file_protocol.ts
Normal file
|
@ -0,0 +1 @@
|
|||
Deno.bench("bench0", () => {});
|
Loading…
Add table
Reference in a new issue