| OLD | NEW |
| 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 infra.libs.infra_types import freeze, thaw | 5 from infra.libs.infra_types import freeze, thaw |
| 6 | 6 |
| 7 DEPS = [ | 7 DEPS = [ |
| 8 'adb', | 8 'adb', |
| 9 'bot_update', | 9 'bot_update', |
| 10 'chromium', | 10 'chromium', |
| (...skipping 85 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 96 api.properties['parent_revision']), | 96 api.properties['parent_revision']), |
| 97 'num_device_shards': 1, | 97 'num_device_shards': 1, |
| 98 'set_component_rev': {'name': 'src/v8', 'rev_str': '%s'}, | 98 'set_component_rev': {'name': 'src/v8', 'rev_str': '%s'}, |
| 99 }, | 99 }, |
| 100 }, | 100 }, |
| 101 }) | 101 }) |
| 102 | 102 |
| 103 def GenSteps(api): | 103 def GenSteps(api): |
| 104 mastername = api.properties['mastername'] | 104 mastername = api.properties['mastername'] |
| 105 buildername = api.properties['buildername'] | 105 buildername = api.properties['buildername'] |
| 106 # TODO(akuegel): Move the configs in builders.py in chromium_tests to this |
| 107 # recipe, and get rid of duplications. |
| 106 builder = thaw(BUILDERS[mastername][buildername]) | 108 builder = thaw(BUILDERS[mastername][buildername]) |
| 107 api.chromium_android.set_config( | 109 api.chromium_android.set_config( |
| 108 builder.get('recipe_config', 'base_config'), REPO_NAME='src', | 110 builder.get('recipe_config', 'base_config'), REPO_NAME='src', |
| 109 REPO_URL=REPO_URL, INTERNAL=False, BUILD_CONFIG='Release', | 111 REPO_URL=REPO_URL, INTERNAL=False, BUILD_CONFIG='Release', |
| 110 TARGET_PLATFORM='android') | 112 TARGET_PLATFORM='android') |
| 111 api.gclient.set_config('perf') | 113 api.gclient.set_config('perf') |
| 112 api.gclient.apply_config('android') | 114 api.gclient.apply_config('android') |
| 113 for c in builder.get('gclient_apply_config', []): | 115 for c in builder.get('gclient_apply_config', []): |
| 114 api.gclient.apply_config(c) | 116 api.gclient.apply_config(c) |
| 115 | 117 |
| (...skipping 12 matching lines...) Expand all Loading... |
| 128 api.gclient.c.revisions[dep['name']] = dep['rev_str'] % component_rev | 130 api.gclient.c.revisions[dep['name']] = dep['rev_str'] % component_rev |
| 129 | 131 |
| 130 api.bot_update.ensure_checkout() | 132 api.bot_update.ensure_checkout() |
| 131 | 133 |
| 132 test_spec_file = builder.get('test_spec_file') | 134 test_spec_file = builder.get('test_spec_file') |
| 133 test_spec = {} | 135 test_spec = {} |
| 134 if test_spec_file: | 136 if test_spec_file: |
| 135 test_spec = api.chromium_tests.read_test_spec(api, test_spec_file) | 137 test_spec = api.chromium_tests.read_test_spec(api, test_spec_file) |
| 136 | 138 |
| 137 scripts_compile_targets = \ | 139 scripts_compile_targets = \ |
| 138 api.chromium.get_compile_targets_for_scripts().json.output | 140 api.chromium_tests.get_compile_targets_for_scripts().json.output |
| 139 | 141 |
| 140 builder['tests'] = api.chromium_tests.generate_tests_from_test_spec( | 142 builder['tests'] = api.chromium_tests.generate_tests_from_test_spec( |
| 141 api, test_spec, builder, buildername, mastername, False, | 143 api, test_spec, builder, buildername, mastername, False, |
| 142 scripts_compile_targets, [api.chromium.steps.generate_script]) | 144 scripts_compile_targets, [api.chromium_tests.steps.generate_script]) |
| 143 | 145 |
| 144 api.path['checkout'] = api.path['slave_build'].join('src') | 146 api.path['checkout'] = api.path['slave_build'].join('src') |
| 145 api.chromium_android.clean_local_files() | 147 api.chromium_android.clean_local_files() |
| 146 | 148 |
| 147 api.chromium_android.download_build(bucket=builder['bucket'], | 149 api.chromium_android.download_build(bucket=builder['bucket'], |
| 148 path=builder['path'](api)) | 150 path=builder['path'](api)) |
| 149 | 151 |
| 150 api.chromium_android.common_tests_setup_steps(perf_setup=True) | 152 api.chromium_android.common_tests_setup_steps(perf_setup=True) |
| 151 | 153 |
| 152 api.chromium_android.adb_install_apk( | 154 api.chromium_android.adb_install_apk( |
| (...skipping 88 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 241 api.override_step_data( | 243 api.override_step_data( |
| 242 'read test spec', | 244 'read test spec', |
| 243 api.json.output({ | 245 api.json.output({ |
| 244 "Android Nexus5 Perf": { | 246 "Android Nexus5 Perf": { |
| 245 "scripts": [ | 247 "scripts": [ |
| 246 { | 248 { |
| 247 "name": "host_info", | 249 "name": "host_info", |
| 248 "script": "host_info.py" | 250 "script": "host_info.py" |
| 249 }]}})) + | 251 }]}})) + |
| 250 api.step_data('host_info', retcode=1)) | 252 api.step_data('host_info', retcode=1)) |
| OLD | NEW |