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

Side by Side Diff: tools/perf/measurements/smooth_gesture_util_unittest.py

Issue 332213003: Move telemetry/core/timeline and timeline_data to telemetry/timeline. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 6 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
OLDNEW
1 # Copyright 2014 The Chromium Authors. All rights reserved. 1 # Copyright 2014 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 unittest 4 import unittest
5 5
6 from telemetry.core.timeline import model as model_module 6 from telemetry.timeline import model as model_module
7 from telemetry.web_perf import timeline_interaction_record as tir_module 7 from telemetry.web_perf import timeline_interaction_record as tir_module
8 from measurements import smooth_gesture_util as sg_util 8 from measurements import smooth_gesture_util as sg_util
9 9
10 class SmoothGestureUtilTest(unittest.TestCase): 10 class SmoothGestureUtilTest(unittest.TestCase):
11 def testGetAdjustedInteractionIfContainGesture(self): 11 def testGetAdjustedInteractionIfContainGesture(self):
12 model = model_module.TimelineModel() 12 model = model_module.TimelineModel()
13 renderer_main = model.GetOrCreateProcess(1).GetOrCreateThread(2) 13 renderer_main = model.GetOrCreateProcess(1).GetOrCreateThread(2)
14 renderer_main.name = 'CrRendererMain' 14 renderer_main.name = 'CrRendererMain'
15 15
16 # [ X ] [ Y ] 16 # [ X ] [ Y ]
(...skipping 46 matching lines...) Expand 10 before | Expand all | Expand 10 after
63 self.assertEquals(adjusted_record_5.start, 35) 63 self.assertEquals(adjusted_record_5.start, 35)
64 self.assertEquals(adjusted_record_5.end, 45) 64 self.assertEquals(adjusted_record_5.end, 45)
65 self.assertTrue(adjusted_record_5 is not record_5) 65 self.assertTrue(adjusted_record_5 is not record_5)
66 66
67 adjusted_record_6 = sg_util.GetAdjustedInteractionIfContainGesture( 67 adjusted_record_6 = sg_util.GetAdjustedInteractionIfContainGesture(
68 model, record_6) 68 model, record_6)
69 self.assertEquals(adjusted_record_6.start, 15) 69 self.assertEquals(adjusted_record_6.start, 15)
70 self.assertEquals(adjusted_record_6.end, 25) 70 self.assertEquals(adjusted_record_6.end, 25)
71 self.assertTrue(adjusted_record_6 is not record_6) 71 self.assertTrue(adjusted_record_6 is not record_6)
72 72
OLDNEW
« no previous file with comments | « tools/perf/measurements/image_decoding.py ('k') | tools/perf/measurements/smoothness_controller.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698