Commit 9e9bef02 authored by wiltzius@chromium.org's avatar wiltzius@chromium.org

swap timed wait for whenPolymerReady function

BUG=400538

Review URL: https://codereview.chromium.org/439893002

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@287861 0039d316-1c4b-4281-b951-d872f2087c98
parent 411895b8
...@@ -112,9 +112,16 @@ class PolymerSampler(PolymerPage): ...@@ -112,9 +112,16 @@ class PolymerSampler(PolymerPage):
#FIXME(wiltzius) workaround for crbug.com/391672 #FIXME(wiltzius) workaround for crbug.com/391672
action_runner.ExecuteJavaScript('window.location.href="about:blank";') action_runner.ExecuteJavaScript('window.location.href="about:blank";')
super(PolymerSampler, self).RunNavigateSteps(action_runner) super(PolymerSampler, self).RunNavigateSteps(action_runner)
#FIXME(wiltzius) this should wait for iframe to load and all load waitForLoadJS = """
# animations to end window.Polymer.whenPolymerReady(function() {
action_runner.Wait(5) %s.contentWindow.Polymer.whenPolymerReady(function() {
window.__polymer_ready = true;
})
});
""" % self.iframe_js
action_runner.ExecuteJavaScript(waitForLoadJS)
action_runner.WaitForJavaScriptCondition(
'window.__polymer_ready')
def RunSmoothness(self, action_runner): def RunSmoothness(self, action_runner):
#TODO(wiltzius) Add interactions for input elements and shadow pages #TODO(wiltzius) Add interactions for input elements and shadow pages
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment