Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(2)

Side by Side Diff: scripts/slave/recipe_modules/perf_try/api.py

Issue 1554383003: Add support for "additional_mirrors" property in trybot configs. (Closed) Base URL: https://chromium.googlesource.com/chromium/tools/build.git@master
Patch Set: Created 4 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 # Copyright 2015 The Chromium Authors. All rights reserved. 1 # Copyright 2015 The Chromium Authors. All rights reserved.
2 # Use of this source code is governed by a BSD-style license that can be 2 # Use of this source code is governed by a BSD-style license that can be
3 # found in the LICENSE file. 3 # found in the LICENSE file.
4 4
5 """API for the perf try job recipe module. 5 """API for the perf try job recipe module.
6 6
7 This API is meant to enable the perf try job recipe on any chromium-supported 7 This API is meant to enable the perf try job recipe on any chromium-supported
8 platform for any test that can be run via buildbot, perf or otherwise. 8 platform for any test that can be run via buildbot, perf or otherwise.
9 """ 9 """
10 10
(...skipping 142 matching lines...) Expand 10 before | Expand all | Expand 10 after
153 self.m.gclient.c.revisions['src'] = str(revision) 153 self.m.gclient.c.revisions['src'] = str(revision)
154 update_step = self.m.bot_update.ensure_checkout( 154 update_step = self.m.bot_update.ensure_checkout(
155 suffix=str(revision), force=True, patch=False, 155 suffix=str(revision), force=True, patch=False,
156 update_presentation=False) 156 update_presentation=False)
157 assert update_step.json.output['did_run'] 157 assert update_step.json.output['did_run']
158 self.m.chromium.runhooks(name='runhooks on %s' % str(revision)) 158 self.m.chromium.runhooks(name='runhooks on %s' % str(revision))
159 159
160 return update_step 160 return update_step
161 161
162 def _compile(self, name, mastername, buildername, update_step, 162 def _compile(self, name, mastername, buildername, update_step,
163 master_dict, test_spec=None): 163 master_dict, test_specs=None):
164 """Runs compile and related steps for given builder.""" 164 """Runs compile and related steps for given builder."""
165 if test_spec is None: 165 if test_specs is None:
166 test_spec = {} 166 test_specs = [{}]
167 compile_targets, _ = self.m.chromium_tests.get_compile_targets_and_tests( 167 compile_targets, _ = self.m.chromium_tests.get_compile_targets_and_tests(
168 mastername, 168 mastername,
169 buildername, 169 buildername,
170 master_dict, 170 [master_dict],
171 test_spec, 171 None,
172 test_specs,
172 override_bot_type='builder_tester', 173 override_bot_type='builder_tester',
173 override_tests=[]) 174 override_tests=[])
174 if self.m.chromium.c.TARGET_PLATFORM == 'android': 175 if self.m.chromium.c.TARGET_PLATFORM == 'android':
175 self.m.chromium_android.clean_local_files() 176 self.m.chromium_android.clean_local_files()
176 compile_targets = None 177 compile_targets = None
177 else: 178 else:
178 # Removes any chrome temporary files or build.dead directories. 179 # Removes any chrome temporary files or build.dead directories.
179 self.m.chromium.cleanup_temp() 180 self.m.chromium.cleanup_temp()
180 181
181 if 'With Patch' in name: 182 if 'With Patch' in name:
(...skipping 260 matching lines...) Expand 10 before | Expand all | Expand 10 after
442 443
443 def _prepend_src_to_path_in_command(test_cfg): 444 def _prepend_src_to_path_in_command(test_cfg):
444 command_to_run = [] 445 command_to_run = []
445 for v in test_cfg.get('command').split(): 446 for v in test_cfg.get('command').split():
446 if v in ['./tools/perf/run_benchmark', 447 if v in ['./tools/perf/run_benchmark',
447 'tools/perf/run_benchmark', 448 'tools/perf/run_benchmark',
448 'tools\\perf\\run_benchmark']: 449 'tools\\perf\\run_benchmark']:
449 v = 'src/tools/perf/run_benchmark' 450 v = 'src/tools/perf/run_benchmark'
450 command_to_run.append(v) 451 command_to_run.append(v)
451 test_cfg.update({'command': ' '.join(command_to_run)}) 452 test_cfg.update({'command': ' '.join(command_to_run)})
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698