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

Unified Diff: build/android/pylib/base/shard.py

Issue 13820024: [Android] Thread names reflect the device serial number they are associated with. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: remove python2.7 specific features Created 7 years, 8 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | build/android/pylib/utils/reraiser_thread.py » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: build/android/pylib/base/shard.py
diff --git a/build/android/pylib/base/shard.py b/build/android/pylib/base/shard.py
index aaa3975cebfcabcf58a929bcc89cf161e49dba9d..c9fc838d1ee837a368253f9f08f08e11e1c53ed1 100644
--- a/build/android/pylib/base/shard.py
+++ b/build/android/pylib/base/shard.py
@@ -205,7 +205,8 @@ def _RunAllTests(runners, tests, timeout=None):
watcher = watchdog_timer.WatchdogTimer(timeout)
workers = reraiser_thread.ReraiserThreadGroup(
[reraiser_thread.ReraiserThread(_RunTestsFromQueue,
- [r, tests_collection, results, watcher])
+ [r, tests_collection, results, watcher],
+ name=r.device[-4:])
for r in runners])
workers.StartAll()
workers.JoinAll(watcher)
@@ -234,8 +235,9 @@ def _CreateRunners(runner_factory, devices, timeout=None):
runners = []
counter = _ThreadSafeCounter()
threads = reraiser_thread.ReraiserThreadGroup(
- [reraiser_thread.ReraiserThread(_SetUp, [runner_factory, d, runners,
- counter])
+ [reraiser_thread.ReraiserThread(_SetUp,
+ [runner_factory, d, runners, counter],
+ name=d[-4:])
for d in devices])
threads.StartAll()
threads.JoinAll(watchdog_timer.WatchdogTimer(timeout))
@@ -249,8 +251,8 @@ def _TearDownRunners(runners, timeout=None):
timeout: watchdog timeout in seconds, defaults to the default timeout.
"""
threads = reraiser_thread.ReraiserThreadGroup(
- [reraiser_thread.ReraiserThread(runner.TearDown)
- for runner in runners])
+ [reraiser_thread.ReraiserThread(r.TearDown, name=r.device[-4:])
+ for r in runners])
threads.StartAll()
threads.JoinAll(watchdog_timer.WatchdogTimer(timeout))
« no previous file with comments | « no previous file | build/android/pylib/utils/reraiser_thread.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698