diff --git a/app/benchmark.gradle b/app/benchmark.gradle index 90823411c..001951d7e 100644 --- a/app/benchmark.gradle +++ b/app/benchmark.gradle @@ -72,6 +72,10 @@ ext.maybeConfigForJetpackBenchmark = { android -> // We set the the output directory simply for simplicity since the benchmark_runner.py script // can't know the name of the phone in the /build/outputs/ directory. The system defaults to // {phone_name} which can be troublesome finding in some case. + + //NOTE: Jetpack Benchmark outputs to Logcat too. However, the output in the logcat is + //the min of the several repeats, for more statistics. Therefore, to get more stats, + //we refer to the JSON file. additionalTestOutputDir : '/storage/emulated/0/benchmark' ] } diff --git a/tools/benchmark_runner.py b/tools/run_benchmark.py similarity index 89% rename from tools/benchmark_runner.py rename to tools/run_benchmark.py index 5d39b0dfa..bf5b73186 100644 --- a/tools/benchmark_runner.py +++ b/tools/run_benchmark.py @@ -21,7 +21,8 @@ def parse_args(): parser = argparse.ArgumentParser(description=DESCRIPTION) parser.add_argument("--class_to_test", help="Path to the class to test. Format it as 'org.mozilla.fenix.[path_to_benchmark_test") - + parser.add_argument("--open_file_in_browser", + help="Open the JSON file in the browser once the tests are done.") return parser.parse_args() @@ -49,7 +50,8 @@ def main(): args = parse_args() run_benchmark(args.class_to_test) fetch_benchmark_results() - open_in_browser() + if args.open_file_in_browser: + open_in_browser() if __name__ == '__main__':