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

Side by Side Diff: build/android/pylib/constants.py

Issue 181433020: GetAttachedDevices() should not include bad devices listed in .bad_devices file. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Add ResetBadDevices and ExtendBadDevices to android_commands.py. Created 6 years, 9 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 | « build/android/pylib/android_commands.py ('k') | 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 """Defines a set of constants shared by test runners and other scripts.""" 5 """Defines a set of constants shared by test runners and other scripts."""
6 6
7 import collections 7 import collections
8 import logging 8 import logging
9 import os 9 import os
10 import subprocess 10 import subprocess
(...skipping 120 matching lines...) Expand 10 before | Expand all | Expand 10 after
131 'third_party/android_tools/sdk') 131 'third_party/android_tools/sdk')
132 ANDROID_SDK_TOOLS = os.path.join(ANDROID_SDK_ROOT, 132 ANDROID_SDK_TOOLS = os.path.join(ANDROID_SDK_ROOT,
133 'build-tools', ANDROID_SDK_BUILD_TOOLS_VERSION) 133 'build-tools', ANDROID_SDK_BUILD_TOOLS_VERSION)
134 ANDROID_NDK_ROOT = os.path.join(DIR_SOURCE_ROOT, 134 ANDROID_NDK_ROOT = os.path.join(DIR_SOURCE_ROOT,
135 'third_party/android_tools/ndk') 135 'third_party/android_tools/ndk')
136 136
137 EMULATOR_SDK_ROOT = os.environ.get('ANDROID_EMULATOR_SDK_ROOT', 137 EMULATOR_SDK_ROOT = os.environ.get('ANDROID_EMULATOR_SDK_ROOT',
138 os.path.join(DIR_SOURCE_ROOT, 138 os.path.join(DIR_SOURCE_ROOT,
139 'android_emulator_sdk')) 139 'android_emulator_sdk'))
140 140
141 BAD_DEVICES_JSON = os.path.join(DIR_SOURCE_ROOT,
142 os.environ.get('CHROMIUM_OUT_DIR', 'out'),
143 'bad_devices.json')
144
141 UPSTREAM_FLAKINESS_SERVER = 'test-results.appspot.com' 145 UPSTREAM_FLAKINESS_SERVER = 'test-results.appspot.com'
142 146
143 147
144 def GetBuildType(): 148 def GetBuildType():
145 try: 149 try:
146 return os.environ['BUILDTYPE'] 150 return os.environ['BUILDTYPE']
147 except KeyError: 151 except KeyError:
148 raise Exception('The BUILDTYPE environment variable has not been set') 152 raise Exception('The BUILDTYPE environment variable has not been set')
149 153
150 154
(...skipping 34 matching lines...) Expand 10 before | Expand all | Expand 10 after
185 subprocess.call(['adb', 'version'], stdout=devnull, stderr=devnull) 189 subprocess.call(['adb', 'version'], stdout=devnull, stderr=devnull)
186 return 'adb' 190 return 'adb'
187 except OSError: 191 except OSError:
188 logging.debug('No adb found in $PATH, fallback to checked in binary.') 192 logging.debug('No adb found in $PATH, fallback to checked in binary.')
189 return os.path.join(ANDROID_SDK_ROOT, 'platform-tools', 'adb') 193 return os.path.join(ANDROID_SDK_ROOT, 'platform-tools', 'adb')
190 194
191 195
192 # Exit codes 196 # Exit codes
193 ERROR_EXIT_CODE = 1 197 ERROR_EXIT_CODE = 1
194 WARNING_EXIT_CODE = 88 198 WARNING_EXIT_CODE = 88
OLDNEW
« no previous file with comments | « build/android/pylib/android_commands.py ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698