| Index: scripts/slave/recipe_modules/webrtc/api.py
|
| diff --git a/scripts/slave/recipe_modules/webrtc/api.py b/scripts/slave/recipe_modules/webrtc/api.py
|
| index 5d9793a4f056a70f9aface0c004ab69b0006cdce..89fcd0ded789705ca1d7dcafed4c42454b19ff60 100644
|
| --- a/scripts/slave/recipe_modules/webrtc/api.py
|
| +++ b/scripts/slave/recipe_modules/webrtc/api.py
|
| @@ -2,6 +2,9 @@
|
| # Use of this source code is governed by a BSD-style license that can be
|
| # found in the LICENSE file.
|
|
|
| +import ast
|
| +import json
|
| +
|
| from slave import recipe_api
|
| from slave.recipe_modules.webrtc import builders
|
|
|
| @@ -67,12 +70,13 @@ class WebRTCApi(recipe_api.RecipeApi):
|
|
|
| DASHBOARD_UPLOAD_URL = 'https://chromeperf.appspot.com'
|
|
|
| - def runtests(self, test_suite=None, revision=None):
|
| + def runtests(self, test_suite=None, revision=None, cr_revision=None):
|
| """Add a suite of test steps.
|
|
|
| Args:
|
| test_suite: The name of the test suite.
|
| revision: Revision for the build. Mandatory for perf measuring tests.
|
| + cr_revision: Chromium revision for the build, where applicable.
|
| """
|
| with self.m.step.defer_results():
|
| if test_suite in ('webrtc', 'webrtc_parallel'):
|
| @@ -176,12 +180,19 @@ class WebRTCApi(recipe_api.RecipeApi):
|
| perf_dashboard_id = perf_dashboard_id or test
|
| assert revision, ('Revision must be specified for perf tests as they '
|
| 'upload data to the perf dashboard.')
|
| + # Ensure we get the WebRTC revision passed as well for bots that builds
|
| + # WebRTC ToT in a Chromium checkout.
|
| + perf_config = self.c.PERF_CONFIG
|
| + if perf_config and cr_revision:
|
| + perf_config_dict = ast.literal_eval(self.c.PERF_CONFIG)
|
| + perf_config_dict['r_webrtc_rev'] = str(revision)
|
| + perf_config = json.dumps(perf_config_dict)
|
| self.m.chromium.runtest(
|
| test=test, args=args, name=name,
|
| results_url=self.DASHBOARD_UPLOAD_URL, annotate='graphing',
|
| xvfb=True, perf_dashboard_id=perf_dashboard_id, test_type=test,
|
| env=env, revision=revision, perf_id=self.c.PERF_ID,
|
| - perf_config=self.c.PERF_CONFIG)
|
| + perf_config=perf_config)
|
| else:
|
| annotate = 'gtest'
|
| python_mode = False
|
|
|