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

Unified Diff: build/android/pylib/local/device/local_device_test_run.py

Issue 2541093004: [Android] Try harder to run every gtest within each try. (Closed)
Patch Set: mikecase comment Created 4 years 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « build/android/pylib/local/device/local_device_monkey_test_run.py ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: build/android/pylib/local/device/local_device_test_run.py
diff --git a/build/android/pylib/local/device/local_device_test_run.py b/build/android/pylib/local/device/local_device_test_run.py
index fabd3aa9af56cbb16a2ed2d0dd326e879bf526d9..1d7ebdf802802258f1c5d275e0b60b69913db8f2 100644
--- a/build/android/pylib/local/device/local_device_test_run.py
+++ b/build/android/pylib/local/device/local_device_test_run.py
@@ -73,8 +73,9 @@ class LocalDeviceTestRun(test_run.TestRun):
thread.exit()
result = None
+ rerun = None
try:
- result = self._RunTest(dev, test)
+ result, rerun = self._RunTest(dev, test)
if isinstance(result, base_test_result.BaseTestResult):
results.AddResult(result)
elif isinstance(result, list):
@@ -84,13 +85,14 @@ class LocalDeviceTestRun(test_run.TestRun):
'Unexpected result type: %s' % type(result).__name__)
except:
if isinstance(tests, test_collection.TestCollection):
- tests.add(test)
+ rerun = test
raise
finally:
if isinstance(tests, test_collection.TestCollection):
+ if rerun:
+ tests.add(rerun)
tests.test_completed()
-
logging.info('Finished running tests on this device.')
class TestsTerminated(Exception):
@@ -117,7 +119,7 @@ class LocalDeviceTestRun(test_run.TestRun):
test_names = (self._GetUniqueTestName(t) for t in tests)
try_results.AddResults(
base_test_result.BaseTestResult(
- t, base_test_result.ResultType.UNKNOWN)
+ t, base_test_result.ResultType.NOTRUN)
for t in test_names if not t.endswith('*'))
try:
« no previous file with comments | « build/android/pylib/local/device/local_device_monkey_test_run.py ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698