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

Side by Side Diff: scripts/master/cros_builders_pools.py

Issue 8305010: Add ChromiumOS Trybot support. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/tools/build/
Patch Set: '' Created 9 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 | « scripts/master/cros_builder_mapping.py ('k') | scripts/master/cros_try_job_git.py » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Property Changes:
Added: svn:eol-style
+ LF
OLDNEW
(Empty)
1 # Copyright (c) 2011 The Chromium Authors. All rights reserved.
2 # Use of this source code is governed by a BSD-style license that can be
3 # found in the LICENSE file.
4
5 """Implement builder selection for CrOS."""
6
7 from master.builders_pools import BuildersPools
8
9 class CrOSBuildersPools(BuildersPools):
10 """Adds support for builder config->name mappings."""
11
12 def __init__(self, default_pool_name, builder_mapping, parent=None):
13 BuildersPools.__init__(self, default_pool_name, parent)
14 self._builder_mapping = builder_mapping
15
16 def Select(self, builder_names=None, pool_name=None):
17 """Returns list of selected builder names.
18
19 Args:
20 builder_names: A list of CrOS build configurations (i.e.,
21 x86-generic-pre-flight-queue) to select.
22 pool_name: The builder pool to look in.
23
24 Returns:
25 A list of buildbot builder names.
26 """
27 # If the user has requested specific build configurations, return the
28 # corresponding builder names.
29 if builder_names:
30 return [self._builder_mapping.get(name) for name in builder_names]
31 else:
32 return BuildersPools.Select(self, None, pool_name)
OLDNEW
« no previous file with comments | « scripts/master/cros_builder_mapping.py ('k') | scripts/master/cros_try_job_git.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698