diff options
author | Valentin Anger <syrupthinker@gryphno.de> | 2020-08-28 15:03:50 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-08-28 09:03:50 -0400 |
commit | 31f32ed8c4082d36ad2a4ea460366c0d57a5ddbc (patch) | |
tree | 2b60111cd53dd4034d1a92ee8caff89d164b7d2d /tools/util_test.py | |
parent | 3d23208019a2c9faaf265ff13ad59f2d04f10079 (diff) |
Move benchmarks to Rust (#7134)
All benchmarks are done in Rust and can be invoked with
`cargo bench`.
Currently this has it's own "harness" that behaves like
`./tools/benchmark.py` did.
Because of this tests inside `cli/bench` are currently not run.
This should be switched to the language provided harness
once the `#[bench]` attribute has been stabilized.
Diffstat (limited to 'tools/util_test.py')
-rwxr-xr-x | tools/util_test.py | 19 |
1 files changed, 1 insertions, 18 deletions
diff --git a/tools/util_test.py b/tools/util_test.py index 8c25b10ed..7ad9b415e 100755 --- a/tools/util_test.py +++ b/tools/util_test.py @@ -2,8 +2,7 @@ import os from test_util import DenoTestCase, run_tests -from util import (parse_exit_code, shell_quote_win, parse_wrk_output, - root_path) +from util import (parse_exit_code, shell_quote_win, root_path) class TestUtil(DenoTestCase): @@ -21,22 +20,6 @@ class TestUtil(DenoTestCase): assert shell_quote_win( 'a"b""c\\d\\"e\\\\') == '"a""b""""c\\d\\\\""e\\\\\\\\"' - def test_parse_wrk_output(self): - f = open(os.path.join(root_path, "tools/testdata/wrk1.txt")) - stats = parse_wrk_output(f.read()) - assert stats['req_per_sec'] == 1837 - assert stats['max_latency'] == 6.25 - - f2 = open(os.path.join(root_path, "tools/testdata/wrk2.txt")) - stats2 = parse_wrk_output(f2.read()) - assert stats2['req_per_sec'] == 53435 - assert stats2['max_latency'] == 6.22 - - f3 = open(os.path.join(root_path, "tools/testdata/wrk3.txt")) - stats3 = parse_wrk_output(f3.read()) - assert stats3['req_per_sec'] == 96037 - assert stats3['max_latency'] == 6.36 - def test_executable_exists(self): assert os.path.exists(self.deno_exe) |