Chromium Code Reviews| Index: tools/perf/page_sets/system_health/loading_stories.py |
| diff --git a/tools/perf/page_sets/system_health/loading_stories.py b/tools/perf/page_sets/system_health/loading_stories.py |
| index 71ec4ff460323d4dfb4fa7d50edafc80911305ee..788971bc1a6d0bc80d92243bdd3697edf0bd038c 100644 |
| --- a/tools/perf/page_sets/system_health/loading_stories.py |
| +++ b/tools/perf/page_sets/system_health/loading_stories.py |
| @@ -174,8 +174,15 @@ class LoadWashingtonPostMobileStory(_LoadingStory): |
| SUPPORTED_PLATFORMS = platforms.MOBILE_ONLY |
| def _DidLoadDocument(self, action_runner): |
| - # Close the popup window. |
| - action_runner.ClickElement(selector='.close') |
| + # Close the popup window. On Nexus 9 (and probably other tables) the popup |
| + # window does not have a "Close" button, instead it has only a "Send link |
| + # to phone" button. So on tablets we run with the popup window open. The |
| + # popup is transparent, so this is mostly an aesthetical issue. |
| + buttonSelector = '.close' |
|
petrcermak
2016/07/19 17:41:24
Same comments as above.
ulan
2016/07/19 17:48:55
Done.
|
| + hasButton = action_runner.EvaluateJavaScript( |
| + '!!document.querySelector("%s")' % buttonSelector) |
| + if hasButton: |
| + action_runner.ClickElement(selector=buttonSelector) |
| class LoadWikipediaStory(_LoadingStory): |