Pass chartjson_result_file to gtest_parallel tests.

Translate --isolate-script-test-perf-output to --chartjson_result_file
and pass it to the test.
That way we can use Chromium's recipe code to report results to the
Perf dashboard.

TBR=phoglund@webrtc.org

Bug: chromium:807737
Change-Id: I2d3479fe29431cc1a8faf9a73b054a5f4ec610a4
Reviewed-on: https://webrtc-review.googlesource.com/47121
Commit-Queue: Edward Lemur <ehmaldonado@webrtc.org>
Reviewed-by: Mirko Bonadei <mbonadei@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#21894}
This commit is contained in:
Edward Lemur 2018-02-01 15:14:53 +01:00 committed by Commit Bot
parent 0488fcf293
commit 0501e1cd97

View File

@ -107,8 +107,7 @@ def _ParseArgs():
parser.add_argument('--store-test-artifacts', action='store_true',
default=False)
# We don't need to implement this flag, and possibly can't, since it's
# intended for results of Telemetry tests. See
# Used to store results of perf tests. See
# https://chromium.googlesource.com/external/github.com/catapult-project/catapult/+/HEAD/dashboard/docs/data-format.md
parser.add_argument('--isolated-script-test-perf-output', type=str,
default=None)
@ -146,6 +145,13 @@ def _ParseArgs():
test_artifacts_dir,
]
# The corresponding flag in WebRTC is called 'chartjson_result_file'.
if options.isolated_script_test_perf_output:
executable_args += [
'--chartjson_result_file',
options.isolated_script_test_perf_output,
]
# GTEST_SHARD_INDEX and GTEST_TOTAL_SHARDS must be removed from the
# environment. Otherwise it will be picked up by the binary, causing a bug
# where only tests in the first shard are executed.