OLD | NEW |
---|---|
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 | 5 |
6 import android_commands | 6 import android_commands |
7 import logging | 7 import logging |
8 import multiprocessing | 8 import multiprocessing |
9 | 9 |
10 from android_commands import errors | 10 from android_commands import errors |
(...skipping 118 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
129 # Retry on devices that didn't have any exception. | 129 # Retry on devices that didn't have any exception. |
130 self.attached_devices = list(retry_devices) | 130 self.attached_devices = list(retry_devices) |
131 if (retry == self.retries - 1 or | 131 if (retry == self.retries - 1 or |
132 len(self.attached_devices) == 0): | 132 len(self.attached_devices) == 0): |
133 all_passed = final_results.ok + test_results.ok | 133 all_passed = final_results.ok + test_results.ok |
134 final_results = test_results | 134 final_results = test_results |
135 final_results.ok = all_passed | 135 final_results.ok = all_passed |
136 break | 136 break |
137 else: | 137 else: |
138 final_results.ok += test_results.ok | 138 final_results.ok += test_results.ok |
139 # Timed out tests are not reported in GetAllBroken(). | |
140 if test_results.timed_out: | |
141 final_results.timed_out = True | |
139 self.tests = [] | 142 self.tests = [] |
140 for t in test_results.GetAllBroken(): | 143 for t in test_results.GetAllBroken(): |
141 self.tests += [t.name] | 144 self.tests += [t.name] |
frankf
2013/01/09 22:11:28
@Craig: Lines 133-143 are completely breaking the
| |
142 if not self.tests: | 145 if not self.tests: |
143 break | 146 break |
144 else: | 147 else: |
145 # We ran out retries, possibly out of healthy devices. | 148 # We ran out retries, possibly out of healthy devices. |
146 # There's no recovery at this point. | 149 # There's no recovery at this point. |
147 raise Exception('Unrecoverable error while retrying test runs.') | 150 raise Exception('Unrecoverable error while retrying test runs.') |
148 self.OnTestsCompleted(test_runners, final_results) | 151 self.OnTestsCompleted(test_runners, final_results) |
149 self._KillHostForwarder() | 152 self._KillHostForwarder() |
150 return final_results | 153 return final_results |
OLD | NEW |