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

Unified Diff: tools/telemetry/telemetry/wait_interaction_unittest.py

Issue 11734036: Add robohornet as an animation test (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 12 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 side-by-side diff with in-line comments
Download patch
Index: tools/telemetry/telemetry/wait_interaction_unittest.py
diff --git a/tools/telemetry/telemetry/scrolling_interaction_unittest.py b/tools/telemetry/telemetry/wait_interaction_unittest.py
similarity index 52%
copy from tools/telemetry/telemetry/scrolling_interaction_unittest.py
copy to tools/telemetry/telemetry/wait_interaction_unittest.py
index c92157fe3b863e209ffc34894256f98e6ade782c..ff55f1925bfda71f3a44f20a42801a5dea37995f 100644
--- a/tools/telemetry/telemetry/scrolling_interaction_unittest.py
+++ b/tools/telemetry/telemetry/wait_interaction_unittest.py
@@ -3,11 +3,11 @@
# found in the LICENSE file.
import os
-from telemetry import scrolling_interaction
+from telemetry import wait_interaction
from telemetry import tab_test_case
-class ScrollingInteractionTest(tab_test_case.TabTestCase):
- def testScrollingInteraction(self):
+class WaitInteractionTest(tab_test_case.TabTestCase):
+ def testWaitInteraction(self):
unittest_data_dir = os.path.join(os.path.dirname(__file__),
'..', 'unittest_data')
self._browser.SetHTTPServerDirectory(unittest_data_dir)
@@ -17,20 +17,10 @@ class ScrollingInteractionTest(tab_test_case.TabTestCase):
self.assertEquals(self._tab.runtime.Evaluate('document.location.pathname;'),
'/blank.html')
- # Make page bigger than window so it's scrollable.
- self._tab.runtime.Execute("""document.body.style.height =
- (2 * window.innerHeight + 1) + 'px';""")
-
- self.assertEquals(self._tab.runtime.Evaluate('document.body.scrollTop'), 0)
-
- i = scrolling_interaction.ScrollingInteraction()
+ i = wait_interaction.WaitInteraction({ 'duration' : '1' })
hartmanng 2013/01/04 15:34:35 Again here, it's probably easier to just have a nu
i.PerformInteraction(self._tab.page, self._tab)
- self.assertEquals(self._tab.runtime.Evaluate(
- 'document.body.scrollTop + window.innerHeight'),
- self._tab.runtime.Evaluate('document.body.scrollHeight'))
-
rendering_stats_deltas = self._tab.runtime.Evaluate(
'window.__renderingStatsDeltas')
- self.assertTrue(rendering_stats_deltas['numFramesSentToScreen'] > 0)
+ self.assertTrue(rendering_stats_deltas['totalTimeInSeconds'] > 0)
hartmanng 2013/01/04 15:34:35 Might want to also check numFramesSentToScreen, ju

Powered by Google App Engine
This is Rietveld 408576698