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

Unified Diff: build/android/pylib/android_commands.py

Issue 22587004: Android: wait for reboot. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 4 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 | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: build/android/pylib/android_commands.py
diff --git a/build/android/pylib/android_commands.py b/build/android/pylib/android_commands.py
index cb72fffba55ae46025c824bdd0e060fa52e658ed..936b3affd52b904b784ce2935e5128a63d901de4 100644
--- a/build/android/pylib/android_commands.py
+++ b/build/android/pylib/android_commands.py
@@ -350,6 +350,11 @@ class AndroidCommands(object):
if full_reboot or not self.IsRootEnabled():
self._adb.SendCommand('reboot')
timeout = 300
+ retries = 1
+ # Wait for the device to disappear.
+ while retries < 10 and self._device in GetAttachedDevices():
frankf 2013/08/09 18:06:29 Ah, makes sense. nit: self.IsOnline()
bulach 2013/08/09 18:17:19 Done.
+ time.sleep(1)
+ retries += 1
else:
self.RestartShell()
timeout = 120
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698