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

Side by Side Diff: PRESUBMIT.py

Issue 10263007: Fix linux_clang default try builder to only compile and not run tests. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years, 7 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 | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 # Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 # Copyright (c) 2012 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 """Top-level presubmit script for Chromium. 5 """Top-level presubmit script for Chromium.
6 6
7 See http://dev.chromium.org/developers/how-tos/depottools/presubmit-scripts 7 See http://dev.chromium.org/developers/how-tos/depottools/presubmit-scripts
8 for more details about the presubmit API built into gcl. 8 for more details about the presubmit API built into gcl.
9 """ 9 """
10 10
(...skipping 310 matching lines...) Expand 10 before | Expand all | Expand 10 after
321 input_api, output_api)) 321 input_api, output_api))
322 results.extend(_CheckSubversionConfig(input_api, output_api)) 322 results.extend(_CheckSubversionConfig(input_api, output_api))
323 return results 323 return results
324 324
325 325
326 def GetPreferredTrySlaves(project, change): 326 def GetPreferredTrySlaves(project, change):
327 affected_files = change.LocalPaths() 327 affected_files = change.LocalPaths()
328 only_objc_files = all(f.endswith(('.mm', '.m')) for f in affected_files) 328 only_objc_files = all(f.endswith(('.mm', '.m')) for f in affected_files)
329 if only_objc_files: 329 if only_objc_files:
330 return ['mac_rel'] 330 return ['mac_rel']
331 preferred = ['win_rel', 'linux_rel', 'mac_rel'] 331 preferred = ['win_rel', 'linux_rel', 'mac_rel']
tfarina 2012/05/01 01:32:19 it would be interesting to have a win_re = '...' f
M-A Ruel 2012/05/01 01:35:41 I'm fine with this idea but this is outside the sc
332 preferred = ['win_rel', 'linux_rel', 'mac_rel', 'linux_clang']
333 if any(f.endswith(('.h', '.cc', '.cpp', '.cxx')) for f in affected_files): 332 if any(f.endswith(('.h', '.cc', '.cpp', '.cxx')) for f in affected_files):
334 preferred.append('linux_clang') 333 preferred.append('linux_clang:compile')
335 aura_re = '_aura[^/]*[.][^/]*' 334 aura_re = '_aura[^/]*[.][^/]*'
336 if any(re.search(aura_re, f) for f in affected_files): 335 if any(re.search(aura_re, f) for f in affected_files):
337 preferred.append('linux_chromeos') 336 preferred.append('linux_chromeos')
338 # Nothing in chrome/ 337 # Nothing in chrome/
339 android_re_list = ('^base/', 338 android_re_list = ('^base/',
340 '^build/common.gypi$', 339 '^build/common.gypi$',
341 '^content/', 340 '^content/',
342 '^ipc/', 341 '^ipc/',
343 '^jingle/', 342 '^jingle/',
344 '^media/', 343 '^media/',
345 '^net/', 344 '^net/',
346 '^sql/') 345 '^sql/')
347 # Nothing that looks like win-only or aura-only 346 # Nothing that looks like win-only or aura-only
348 win_re = '_win\.(cc|h)$' 347 win_re = '_win\.(cc|h)$'
349 possibly_android = True 348 possibly_android = True
350 for non_android_re in (aura_re, win_re): 349 for non_android_re in (aura_re, win_re):
351 if all(re.search(non_android_re, f) for f in affected_files): 350 if all(re.search(non_android_re, f) for f in affected_files):
352 possibly_android = False 351 possibly_android = False
353 break 352 break
354 if possibly_android: 353 if possibly_android:
355 for f in change.AffectedFiles(): 354 for f in change.AffectedFiles():
356 if any(re.search(r, f.LocalPath()) for r in android_re_list): 355 if any(re.search(r, f.LocalPath()) for r in android_re_list):
357 preferred.append('android') 356 preferred.append('android')
358 break 357 break
359 return preferred 358 return preferred
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698