| 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 """Swarming staging recipe: runs tests for HEAD of chromium using HEAD of | 5 """Swarming staging recipe: runs tests for HEAD of chromium using HEAD of |
| 6 swarming_client toolset on Swarming staging server instances | 6 swarming_client toolset on Swarming staging server instances |
| 7 (*-dev.appspot.com). | 7 (*-dev.appspot.com). |
| 8 | 8 |
| 9 Intended to catch bugs in swarming_client and Swarming servers early on, before | 9 Intended to catch bugs in swarming_client and Swarming servers early on, before |
| 10 full roll out. | 10 full roll out. |
| (...skipping 162 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 173 if not api.properties.get('platform') == 'android': | 173 if not api.properties.get('platform') == 'android': |
| 174 # TODO(estaab): Move this into the swarming recipe_module behind a flag | 174 # TODO(estaab): Move this into the swarming recipe_module behind a flag |
| 175 # after testing on staging. | 175 # after testing on staging. |
| 176 step_result = api.step.active_result | 176 step_result = api.step.active_result |
| 177 gtest_results = getattr(step_result.test_utils, 'gtest_results', None) | 177 gtest_results = getattr(step_result.test_utils, 'gtest_results', None) |
| 178 if gtest_results and gtest_results.raw: | 178 if gtest_results and gtest_results.raw: |
| 179 # This is a potentially large json file (on the order of 10s of MiB) | 179 # This is a potentially large json file (on the order of 10s of MiB) |
| 180 # but swarming/api.py is already parsing it to get failed shards so we | 180 # but swarming/api.py is already parsing it to get failed shards so we |
| 181 # reuse it here. | 181 # reuse it here. |
| 182 parsed_gtest_data = gtest_results.raw | 182 parsed_gtest_data = gtest_results.raw |
| 183 chrome_revision_cp = api.bot_update.properties.get( | 183 chrome_revision_cp = api.bot_update.last_returned_properties.get( |
| 184 'got_revision_cp', 'x@{#0}') | 184 'got_revision_cp', 'x@{#0}') |
| 185 chrome_revision = str(api.commit_position.parse_revision( | 185 chrome_revision = str(api.commit_position.parse_revision( |
| 186 chrome_revision_cp)) | 186 chrome_revision_cp)) |
| 187 api.test_results.upload( | 187 api.test_results.upload( |
| 188 api.json.input(parsed_gtest_data), | 188 api.json.input(parsed_gtest_data), |
| 189 chrome_revision=chrome_revision, | 189 chrome_revision=chrome_revision, |
| 190 test_type=task.title, | 190 test_type=task.title, |
| 191 test_results_server='test-results-test.appspot.com') | 191 test_results_server='test-results-test.appspot.com') |
| 192 | 192 |
| 193 | 193 |
| (...skipping 26 matching lines...) Expand all Loading... |
| 220 api.test('android') + | 220 api.test('android') + |
| 221 api.platform.name('linux') + | 221 api.platform.name('linux') + |
| 222 api.properties.scheduled() + | 222 api.properties.scheduled() + |
| 223 api.properties(configuration='Release', platform='android') + | 223 api.properties(configuration='Release', platform='android') + |
| 224 api.override_step_data( | 224 api.override_step_data( |
| 225 'isolate tests', | 225 'isolate tests', |
| 226 api.isolate.output_json(targets=[ | 226 api.isolate.output_json(targets=[ |
| 227 'dummy_target_1', 'dummy_target_2', 'chrome_public_test_apk']) | 227 'dummy_target_1', 'dummy_target_2', 'chrome_public_test_apk']) |
| 228 ) | 228 ) |
| 229 ) | 229 ) |
| OLD | NEW |