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

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

Issue 620703002: Add isolate.clean_isolated_files and use in all related recipes. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/tools/build
Patch Set: Created 6 years, 2 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 | Annotate | Revision Log
« no previous file with comments | « no previous file | scripts/slave/recipe_modules/gpu/api.py » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 # Copyright 2014 The Chromium Authors. All rights reserved. 1 # Copyright 2014 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 import copy 5 import copy
6 6
7 from slave import recipe_api 7 from slave import recipe_api
8 8
9 9
10 # Different types of builds this recipe module can do. 10 # Different types of builds this recipe module can do.
(...skipping 214 matching lines...) Expand 10 before | Expand all | Expand 10 after
225 225
226 if bot_type in ['builder', 'builder_tester']: 226 if bot_type in ['builder', 'builder_tester']:
227 compile_targets = set(bot_config.get('compile_targets', [])) 227 compile_targets = set(bot_config.get('compile_targets', []))
228 tests_including_triggered = tests[:] 228 tests_including_triggered = tests[:]
229 for loop_buildername, builder_dict in master_dict.get( 229 for loop_buildername, builder_dict in master_dict.get(
230 'builders', {}).iteritems(): 230 'builders', {}).iteritems():
231 if builder_dict.get('parent_buildername') == buildername: 231 if builder_dict.get('parent_buildername') == buildername:
232 for test in builder_dict.get('tests', []): 232 for test in builder_dict.get('tests', []):
233 tests_including_triggered.append(test) 233 tests_including_triggered.append(test)
234 234
235 isolated_targets = [
236 t.name for t in tests_including_triggered if t.uses_swarming
237 ]
238
239 if isolated_targets:
240 self.m.isolate.clean_isolated_files(self.m.chromium.output_dir)
241
235 for t in tests_including_triggered: 242 for t in tests_including_triggered:
236 compile_targets.update(t.compile_targets(self.m)) 243 compile_targets.update(t.compile_targets(self.m))
237 244
238 self.m.chromium.compile(targets=sorted(compile_targets)) 245 self.m.chromium.compile(targets=sorted(compile_targets))
239 self.m.chromium.checkdeps() 246 self.m.chromium.checkdeps()
240 247
241 if self.m.chromium.c.TARGET_PLATFORM == 'android': 248 if self.m.chromium.c.TARGET_PLATFORM == 'android':
242 self.m.chromium_android.check_webview_licenses() 249 self.m.chromium_android.check_webview_licenses()
243 self.m.chromium_android.findbugs() 250 self.m.chromium_android.findbugs()
244 251
245 isolated_targets = [
246 t.name for t in tests_including_triggered if t.uses_swarming
247 ]
248 if isolated_targets: 252 if isolated_targets:
249 self.m.isolate.find_isolated_tests( 253 self.m.isolate.find_isolated_tests(
250 self.m.chromium.output_dir, targets=list(set(isolated_targets))) 254 self.m.chromium.output_dir, targets=list(set(isolated_targets)))
251 255
252 got_revision = update_step.presentation.properties['got_revision'] 256 got_revision = update_step.presentation.properties['got_revision']
253 257
254 if bot_type == 'builder': 258 if bot_type == 'builder':
255 if mastername == 'chromium.linux': 259 if mastername == 'chromium.linux':
256 # TODO(samuong): This is restricted to Linux for now until I have more 260 # TODO(samuong): This is restricted to Linux for now until I have more
257 # confidence that it is not totally broken. 261 # confidence that it is not totally broken.
(...skipping 63 matching lines...) Expand 10 before | Expand all | Expand 10 after
321 self.m.chromium.crash_handler() 325 self.m.chromium.crash_handler()
322 326
323 try: 327 try:
324 return test_runner() 328 return test_runner()
325 finally: 329 finally:
326 if self.m.platform.is_win: 330 if self.m.platform.is_win:
327 self.m.chromium.process_dumps() 331 self.m.chromium.process_dumps()
328 332
329 if self.m.chromium.c.TARGET_PLATFORM == 'android': 333 if self.m.chromium.c.TARGET_PLATFORM == 'android':
330 self.m.chromium_android.common_tests_final_steps() 334 self.m.chromium_android.common_tests_final_steps()
OLDNEW
« no previous file with comments | « no previous file | scripts/slave/recipe_modules/gpu/api.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698