summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--chrome/test/functional/popups.py12
1 files changed, 12 insertions, 0 deletions
diff --git a/chrome/test/functional/popups.py b/chrome/test/functional/popups.py
index fc25a73..f2570b1 100644
--- a/chrome/test/functional/popups.py
+++ b/chrome/test/functional/popups.py
@@ -5,6 +5,7 @@
# found in the LICENSE file.
import os
+import logging
import pyauto_functional # Must be imported before pyauto
import pyauto
@@ -66,6 +67,17 @@ class PopupsTest(pyauto.PyUITest):
file_url = self.GetFileURLForPath(os.path.join(
self.DataDir(), 'popup_blocker', 'popup-window-open.html'))
self.NavigateToURL(file_url, 1, 0)
+ # TODO(sunandt): Work around for debugging the flakiness
+ # Related to crbug.com/64274
+ attempts = 0
+ while attempts < 3:
+ if self.GetActiveTabTitle(window_index=1) != \
+ 'Popup created using window.open':
+ logging.debug('Attempt %s' % attempts+1)
+ self.NavigateToURL(file_url, 1, 0)
+ attempts = attempts + 1
+ else:
+ break
self.assertEquals('Popup created using window.open',
self.GetActiveTabTitle(window_index=1))
# Wait until the popup is blocked