diff --git a/deeplearning/ml4pl/graphs/labelled/dataflow/BUILD b/deeplearning/ml4pl/graphs/labelled/dataflow/BUILD index 4469607a7..55ff37ccc 100644 --- a/deeplearning/ml4pl/graphs/labelled/dataflow/BUILD +++ b/deeplearning/ml4pl/graphs/labelled/dataflow/BUILD @@ -55,6 +55,7 @@ py_test( size = "enormous", timeout = "eternal", srcs = ["annotators_benchmark_test.py"], + args = ["--pytest_args=--benchmark-warmup-iterations=2"], deps = [ ":annotate", ":data_flow_graphs", diff --git a/labm8/py/test.py b/labm8/py/test.py index e94551d29..ffc27b03f 100644 --- a/labm8/py/test.py +++ b/labm8/py/test.py @@ -263,11 +263,6 @@ def RunPytestOnFileOrDie(file_path: str, capture_output: bool = None): # Add the --pytest_args requested by the user. pytest_args += FLAGS.pytest_args - # Allow the user to add a PYTEST_ARGS = ['--foo'] list of additional - # arguments. - if hasattr(test_module, "PYTEST_ARGS"): - pytest_args += test_module.PYTEST_ARGS - with CoverageContext(test_module, file_path, pytest_args) as pytest_args: app.Log(1, "Running pytest with arguments: %s", pytest_args) ret = pytest.main(pytest_args)