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

Side by Side Diff: scripts/slave/recipe_modules/chromium_android/example.py

Issue 2122313002: Move known_devices file to ~/.android (Closed) Base URL: https://chromium.googlesource.com/chromium/tools/build.git@master
Patch Set: with expectations Created 4 years, 5 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.types import freeze 5 from recipe_engine.types import freeze
6 6
7 DEPS = [ 7 DEPS = [
8 'adb', 8 'adb',
9 'chromium', 9 'chromium',
10 'chromium_android', 10 'chromium_android',
(...skipping 139 matching lines...) Expand 10 before | Expand all | Expand 10 after
150 api.chromium_android.adb_install_apk('Chrome.apk', devices=['abc123']) 150 api.chromium_android.adb_install_apk('Chrome.apk', devices=['abc123'])
151 151
152 api.adb.root_devices() 152 api.adb.root_devices()
153 api.chromium_android.spawn_logcat_monitor() 153 api.chromium_android.spawn_logcat_monitor()
154 154
155 failure = False 155 failure = False
156 try: 156 try:
157 # TODO(luqui): remove redundant cruft, need one consistent API. 157 # TODO(luqui): remove redundant cruft, need one consistent API.
158 api.chromium_android.detect_and_setup_devices() 158 api.chromium_android.detect_and_setup_devices()
159 159
160 api.path.mock_add_paths(api.chromium_android.known_devices_file)
160 api.chromium_android.device_status_check( 161 api.chromium_android.device_status_check(
161 restart_usb=config.get('restart_usb', False)) 162 restart_usb=config.get('restart_usb', False))
162 163
163 api.chromium_android.provision_devices( 164 api.chromium_android.provision_devices(
164 skip_wipe=config.get('skip_wipe', False), 165 skip_wipe=config.get('skip_wipe', False),
165 disable_location=config.get('disable_location', False), 166 disable_location=config.get('disable_location', False),
166 min_battery_level=config.get('min_battery_level'), 167 min_battery_level=config.get('min_battery_level'),
167 max_battery_temp=config.get('max_battery_temp'), 168 max_battery_temp=config.get('max_battery_temp'),
168 reboot_timeout=1800, 169 reboot_timeout=1800,
169 remove_system_webview=config.get('remove_system_webview', False), 170 remove_system_webview=config.get('remove_system_webview', False),
(...skipping 204 matching lines...) Expand 10 before | Expand all | Expand 10 after
374 stream='stdout')) + 375 stream='stdout')) +
375 api.override_step_data('Read test result and report failures', 376 api.override_step_data('Read test result and report failures',
376 api.raw_io.output(result_xml_with_unexpected_failure_method))) 377 api.raw_io.output(result_xml_with_unexpected_failure_method)))
377 378
378 yield (api.test('webview_cts_invalid_output') + 379 yield (api.test('webview_cts_invalid_output') +
379 properties_for('webview_cts') + 380 properties_for('webview_cts') +
380 api.override_step_data('Run CTS', api.raw_io.stream_output( 381 api.override_step_data('Run CTS', api.raw_io.stream_output(
381 'Invalid CTS output here...', 382 'Invalid CTS output here...',
382 stream='stdout'))) 383 stream='stdout')))
383 384
384 yield (api.test('device_file_match') +
385 properties_for('tester') +
386 api.path.exists(
387 api.path['build'].join('site_config', '.known_devices')))
388
389 yield (api.test('device_file_format_mismatch') + 385 yield (api.test('device_file_format_mismatch') +
390 properties_for('tester') + 386 properties_for('tester') +
391 api.path.exists(
392 api.path['cache'].join('known_android_devices')) +
393 api.override_step_data('fix_device_file_format.read_device_file', 387 api.override_step_data('fix_device_file_format.read_device_file',
394 api.raw_io.output('["device1", "device2"]'))) 388 api.raw_io.output('["device1", "device2"]')))
395 389
396 yield (api.test('tombstones_m53') + 390 yield (api.test('tombstones_m53') +
397 properties_for('tester') + 391 properties_for('tester') +
398 api.override_step_data('get version (2)', 392 api.override_step_data('get version (2)',
399 api.raw_io.output('MAJOR=53\nMINOR=0\nBUILD=2800\nPATCH=0\n'))) 393 api.raw_io.output('MAJOR=53\nMINOR=0\nBUILD=2800\nPATCH=0\n')))
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698