summaryrefslogtreecommitdiffstats
path: root/build
diff options
context:
space:
mode:
authorbulach@chromium.org <bulach@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2013-08-12 13:12:12 +0000
committerbulach@chromium.org <bulach@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2013-08-12 13:12:12 +0000
commitd1f84206232c08db2af3b4ff5bfeb5243e6b892e (patch)
treec0f682511405d8d52cd2a3e03b8b3ad2a684e56d /build
parentde5b194ada265549422836d330ae8d226716b50d (diff)
downloadchromium_src-d1f84206232c08db2af3b4ff5bfeb5243e6b892e.zip
chromium_src-d1f84206232c08db2af3b4ff5bfeb5243e6b892e.tar.gz
chromium_src-d1f84206232c08db2af3b4ff5bfeb5243e6b892e.tar.bz2
Android: wait for reboot.
On some devices, "reboot" is not synchronous, so the Reboot() call and its internal waits were finishing before the device had even started rebooting. BUG=265425 Review URL: https://chromiumcodereview.appspot.com/22587004 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@216979 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'build')
-rw-r--r--build/android/pylib/android_commands.py5
1 files changed, 5 insertions, 0 deletions
diff --git a/build/android/pylib/android_commands.py b/build/android/pylib/android_commands.py
index cb72fff..f8c0747 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.IsOnline():
+ time.sleep(1)
+ retries += 1
else:
self.RestartShell()
timeout = 120