autotest: Replace WaitForJavaScriptExpression with WaitForJavaScriptCondition.
BUG=chromium:682812
TEST=trybot
Change-Id: I8a71fe24c04f31d401a1925251c5d221accb4d46
Reviewed-on: https://chromium-review.googlesource.com/436528
Commit-Ready: Achuith Bhandarkar <achuith@chromium.org>
Tested-by: Achuith Bhandarkar <achuith@chromium.org>
Reviewed-by: Jacob Dufault <jdufault@chromium.org>
diff --git a/client/common_lib/cros/enrollment.py b/client/common_lib/cros/enrollment.py
index 5f38cf1..9973099 100644
--- a/client/common_lib/cros/enrollment.py
+++ b/client/common_lib/cros/enrollment.py
@@ -11,8 +11,8 @@
def _ExecuteOobeCmd(browser, cmd):
logging.info('Invoking ' + cmd)
oobe = browser.oobe
- oobe.WaitForJavaScriptExpression('typeof Oobe !== \'undefined\'',
- timeout=10)
+ oobe.WaitForJavaScriptCondition('typeof Oobe !== \'undefined\'',
+ timeout=10)
oobe.ExecuteJavaScript(cmd)