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

Side by Side Diff: tools/telemetry/telemetry/scrolling_action_unittest.py

Issue 12294002: Revert 182991 (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 7 years, 10 months 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « tools/telemetry/telemetry/scrolling_action.py ('k') | tools/telemetry/telemetry/simple_mock.py » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 # Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 # Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 # Use of this source code is governed by a BSD-style license that can be 2 # Use of this source code is governed by a BSD-style license that can be
3 # found in the LICENSE file. 3 # found in the LICENSE file.
4 import os 4 import os
5 5
6 from telemetry.page import Page 6 from telemetry.page import Page
7 from telemetry import scrolling_action 7 from telemetry import scrolling_action
8 from telemetry import tab_test_case 8 from telemetry import tab_test_case
9 9
10 class ScrollingActionTest(tab_test_case.TabTestCase): 10 class ScrollingActionTest(tab_test_case.TabTestCase):
(...skipping 71 matching lines...) Expand 10 before | Expand all | Expand 10 after
82 __ScrollingAction_GetBoundingVisibleRect(document.body).top + 82 __ScrollingAction_GetBoundingVisibleRect(document.body).top +
83 __ScrollingAction_GetBoundingVisibleRect(document.body).height""")) 83 __ScrollingAction_GetBoundingVisibleRect(document.body).height"""))
84 rect_right = int(self._tab.EvaluateJavaScript(""" 84 rect_right = int(self._tab.EvaluateJavaScript("""
85 __ScrollingAction_GetBoundingVisibleRect(document.body).left + 85 __ScrollingAction_GetBoundingVisibleRect(document.body).left +
86 __ScrollingAction_GetBoundingVisibleRect(document.body).width""")) 86 __ScrollingAction_GetBoundingVisibleRect(document.body).width"""))
87 viewport_width = int(self._tab.EvaluateJavaScript('window.innerWidth')) 87 viewport_width = int(self._tab.EvaluateJavaScript('window.innerWidth'))
88 viewport_height = int(self._tab.EvaluateJavaScript('window.innerHeight')) 88 viewport_height = int(self._tab.EvaluateJavaScript('window.innerHeight'))
89 89
90 self.assertTrue(rect_bottom <= viewport_height) 90 self.assertTrue(rect_bottom <= viewport_height)
91 self.assertTrue(rect_right <= viewport_width) 91 self.assertTrue(rect_right <= viewport_width)
OLDNEW
« no previous file with comments | « tools/telemetry/telemetry/scrolling_action.py ('k') | tools/telemetry/telemetry/simple_mock.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698