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

Unified Diff: tools/perf/page_sets/system_health/browsing_stories.py

Issue 2497023002: [SystemHealth] Wait for element to exist before trying to scroll to it in browsing stories. (Closed)
Patch Set: Created 4 years, 1 month 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: tools/perf/page_sets/system_health/browsing_stories.py
diff --git a/tools/perf/page_sets/system_health/browsing_stories.py b/tools/perf/page_sets/system_health/browsing_stories.py
index f8527e0634736fc3f57a5fc87f13e51b531ebfa8..27c577deed0b635331a29d8f8820f003582293de 100644
--- a/tools/perf/page_sets/system_health/browsing_stories.py
+++ b/tools/perf/page_sets/system_health/browsing_stories.py
@@ -30,6 +30,7 @@ class _BrowsingStory(system_health_story.SystemHealthStory):
item_selector = 'document.querySelectorAll("%s")[%d]' % (
self.ITEM_SELECTOR, index)
# Only scrolls if element is not currently in viewport.
+ action_runner.WaitForElement(element_function=item_selector)
action_runner.ScrollPageToElement(element_function=item_selector)
self._ClickLink(action_runner, item_selector)
« 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