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

Side by Side Diff: scripts/slave/recipe_modules/chromium/test_api.py

Issue 1185693002: Move builders.py and steps.py to chromium_tests. (Closed) Base URL: https://chromium.googlesource.com/chromium/tools/build.git@master
Patch Set: Address review comments. Created 5 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
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 from recipe_engine import recipe_test_api 5 from recipe_engine import recipe_test_api
6 6
7 from . import builders
8
9 7
10 class ChromiumTestApi(recipe_test_api.RecipeTestApi): 8 class ChromiumTestApi(recipe_test_api.RecipeTestApi):
11 @property
12 def builders(self):
13 return builders.BUILDERS
14
15 def gen_tests_for_builders(self, builder_dict, overrides=None): 9 def gen_tests_for_builders(self, builder_dict, overrides=None):
16 # TODO: crbug.com/354674. Figure out where to put "simulation" 10 # TODO: crbug.com/354674. Figure out where to put "simulation"
17 # tests. Is this really the right place? 11 # tests. Is this really the right place?
18 12
19 def _sanitize_nonalpha(text): 13 def _sanitize_nonalpha(text):
20 return ''.join(c if c.isalnum() else '_' for c in text) 14 return ''.join(c if c.isalnum() else '_' for c in text)
21 15
22 overrides = overrides or {} 16 overrides = overrides or {}
23 for mastername in builder_dict: 17 for mastername in builder_dict:
24 for buildername in builder_dict[mastername]['builders']: 18 for buildername in builder_dict[mastername]['builders']:
(...skipping 13 matching lines...) Expand all
38 mastername=mastername) 32 mastername=mastername)
39 else: 33 else:
40 test += self.m.properties.generic(buildername=buildername, 34 test += self.m.properties.generic(buildername=buildername,
41 mastername=mastername) 35 mastername=mastername)
42 36
43 override_step_data = overrides.get(mastername, {}).get(buildername, 37 override_step_data = overrides.get(mastername, {}).get(buildername,
44 None) 38 None)
45 if override_step_data: 39 if override_step_data:
46 test += override_step_data 40 test += override_step_data
47 yield test 41 yield test
OLDNEW
« no previous file with comments | « scripts/slave/recipe_modules/chromium/steps.py ('k') | scripts/slave/recipe_modules/chromium/tryserver_chromium_linux.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698