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

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

Issue 2073923002: Support sharding for swarmed isolated script tests. (Closed) Base URL: https://chromium.googlesource.com/chromium/tools/build.git@master
Patch Set: Explicitly handle missing shards' output. Created 4 years, 6 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
« no previous file with comments | « no previous file | scripts/slave/recipe_modules/swarming/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 re 5 import re
6 import string 6 import string
7 7
8 8
9 class Test(object): 9 class Test(object):
10 """ 10 """
(...skipping 1208 matching lines...) Expand 10 before | Expand all | Expand 10 after
1219 browser_config = api.chromium.c.build_config_fs.lower() 1219 browser_config = api.chromium.c.build_config_fs.lower()
1220 args = self._args[:] 1220 args = self._args[:]
1221 1221
1222 # TODO(nednguyen): only rerun the tests that failed for the "without patch" 1222 # TODO(nednguyen): only rerun the tests that failed for the "without patch"
1223 # suffix. 1223 # suffix.
1224 1224
1225 # For the time being, we assume all isolated_script_test are not idempotent 1225 # For the time being, we assume all isolated_script_test are not idempotent
1226 # TODO(nednguyen): make this configurable in isolated_scripts's spec. 1226 # TODO(nednguyen): make this configurable in isolated_scripts's spec.
1227 return api.swarming.isolated_script_task( 1227 return api.swarming.isolated_script_task(
1228 title=self._step_name(suffix), isolated_hash=isolated_hash, 1228 title=self._step_name(suffix), isolated_hash=isolated_hash,
1229 idempotent=False, extra_args=args) 1229 shards=self._shards, idempotent=False, extra_args=args)
1230 1230
1231 def validate_task_results(self, api, step_result): 1231 def validate_task_results(self, api, step_result):
1232 results = getattr(step_result, 'isolated_script_results', None) or {} 1232 results = getattr(step_result, 'isolated_script_results', None) or {}
1233 1233
1234 try: 1234 try:
1235 failures = results['failures'] 1235 failures = results['failures']
1236 valid = results['valid'] 1236 valid = results['valid']
1237 if not failures and step_result.retcode != 0: 1237 if not failures and step_result.retcode != 0:
1238 failures = ['%s (entire test suite)' % self.name] 1238 failures = ['%s (entire test suite)' % self.name]
1239 valid = False 1239 valid = False
(...skipping 621 matching lines...) Expand 10 before | Expand all | Expand 10 after
1861 def run(self, api, suffix, test_filter=None): 1861 def run(self, api, suffix, test_filter=None):
1862 api.chromium_android.coverage_report(upload=False) 1862 api.chromium_android.coverage_report(upload=False)
1863 api.chromium_android.get_changed_lines_for_revision() 1863 api.chromium_android.get_changed_lines_for_revision()
1864 api.chromium_android.incremental_coverage_report() 1864 api.chromium_android.incremental_coverage_report()
1865 1865
1866 1866
1867 GOMA_TESTS = [ 1867 GOMA_TESTS = [
1868 GTestTest('base_unittests'), 1868 GTestTest('base_unittests'),
1869 GTestTest('content_unittests'), 1869 GTestTest('content_unittests'),
1870 ] 1870 ]
OLDNEW
« no previous file with comments | « no previous file | scripts/slave/recipe_modules/swarming/api.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698