[Session restore] Rename group name Enabled to Restore.
[chromium-blink-merge.git] / tools / perf / page_sets / tough_animation_cases.py
blob5c458d8b8261545eaf055e6a892a7a14e0a841ab
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
3 # found in the LICENSE file.
4 from telemetry.page import page as page_module
5 from telemetry.page import page_set as page_set_module
8 class ToughAnimationCasesPage(page_module.Page):
10 def __init__(self, url, page_set, need_measurement_ready):
11 super(ToughAnimationCasesPage, self).__init__(url=url, page_set=page_set)
12 self.archive_data_file = 'data/tough_animation_cases.json'
13 self._need_measurement_ready = need_measurement_ready
15 def RunNavigateSteps(self, action_runner):
16 super(ToughAnimationCasesPage, self).RunNavigateSteps(action_runner)
17 if self._need_measurement_ready:
18 action_runner.WaitForJavaScriptCondition('window.measurementReady')
20 def RunPageInteractions(self, action_runner):
21 action_runner.Wait(10)
23 class ToughAnimationCasesPageSet(page_set_module.PageSet):
25 """
26 Description: A collection of animation performance tests
27 """
29 def __init__(self):
30 super(ToughAnimationCasesPageSet, self).__init__(
31 archive_data_file='data/tough_animation_cases.json',
32 bucket=page_set_module.PARTNER_BUCKET)
34 urls_list_one = [
35 # Why: Tests the balls animation implemented with SVG animations.
36 'file://tough_animation_cases/balls_svg_animations.html',
37 # Why: Tests the balls animation implemented with Javascript and canvas.
38 'file://tough_animation_cases/balls_javascript_canvas.html',
39 # Why: Tests the balls animation implemented with Javascript and CSS.
40 'file://tough_animation_cases/balls_javascript_css.html',
41 # Why: Tests the balls animation implemented with CSS keyframe animations.
42 'file://tough_animation_cases/balls_css_keyframe_animations.html',
43 # Why: Tests the balls animation implemented with transforms and CSS
44 # keyframe animations to be run on the compositor thread.
45 # pylint: disable=C0301
46 'file://tough_animation_cases/balls_css_keyframe_animations_composited_transform.html',
47 # Why: Tests the balls animation implemented with CSS transitions on 2
48 # properties.
49 'file://tough_animation_cases/balls_css_transition_2_properties.html',
50 # Why: Tests the balls animation implemented with CSS transitions on 40
51 # properties.
52 'file://tough_animation_cases/balls_css_transition_40_properties.html',
53 # Why: Tests the balls animation implemented with CSS transitions on all
54 # animatable properties.
55 'file://tough_animation_cases/balls_css_transition_all_properties.html',
56 # pylint: disable=C0301
57 'file://tough_animation_cases/overlay_background_color_css_transitions.html',
59 # Why: Tests many CSS Transitions all starting at the same time triggered
60 # by inserting new elements.
61 # pylint: disable=C0301
62 'file://tough_animation_cases/css_transitions_simultaneous_by_inserting_new_element.html?N=0316',
63 # Why: Tests many CSS Transitions all starting at the same time triggered
64 # by inserting style sheets.
65 # pylint: disable=C0301
66 'file://tough_animation_cases/css_transitions_simultaneous_by_inserting_style_element.html?N=0316',
67 # Why: Tests many CSS Transitions all starting at the same time triggered
68 # by updating class.
69 # pylint: disable=C0301
70 'file://tough_animation_cases/css_transitions_simultaneous_by_updating_class.html?N=0316',
71 # Why: Tests many CSS Transitions all starting at the same time triggered
72 # by updating inline style.
73 # pylint: disable=C0301
74 'file://tough_animation_cases/css_transitions_simultaneous_by_updating_inline_style.html?N=0316',
75 # Why: Tests many CSS Transitions chained together using events at
76 # different times triggered by inserting new elements.
77 # pylint: disable=C0301
78 'file://tough_animation_cases/css_transitions_staggered_chaining_by_inserting_new_element.html?N=0316',
79 # Why: Tests many CSS Transitions chained together using events at
80 # different times triggered by inserting style sheets.
81 # pylint: disable=C0301
82 'file://tough_animation_cases/css_transitions_staggered_chaining_by_inserting_style_element.html?N=0316',
83 # Why: Tests many CSS Transitions chained together using events at
84 # different times triggered by updating class.
85 # pylint: disable=C0301
86 'file://tough_animation_cases/css_transitions_staggered_chaining_by_updating_class.html?N=0316',
87 # Why: Tests many CSS Transitions chained together using events at
88 # different times triggered by updating inline style.
89 # pylint: disable=C0301
90 'file://tough_animation_cases/css_transitions_staggered_chaining_by_updating_inline_style.html?N=0316',
91 # Why: Tests many CSS Transitions starting at different times triggered by
92 # inserting new elements.
93 # pylint: disable=C0301
94 'file://tough_animation_cases/css_transitions_staggered_triggering_by_inserting_new_element.html?N=0316',
95 # Why: Tests many CSS Transitions starting at different times triggered by
96 # inserting style sheets.
97 # pylint: disable=C0301
98 'file://tough_animation_cases/css_transitions_staggered_triggering_by_inserting_style_element.html?N=0316',
99 # Why: Tests many CSS Transitions starting at different times triggered by
100 # updating class.
101 # pylint: disable=C0301
102 'file://tough_animation_cases/css_transitions_staggered_triggering_by_updating_class.html?N=0316',
103 # Why: Tests many CSS Transitions starting at different times triggered by
104 # updating inline style.
105 # pylint: disable=C0301
106 'file://tough_animation_cases/css_transitions_staggered_triggering_by_updating_inline_style.html?N=0316',
108 # Why: Tests many CSS Animations all starting at the same time with 500
109 # keyframes each.
110 'file://tough_animation_cases/css_animations_many_keyframes.html?N=0316',
111 # Why: Tests many CSS Animations all starting at the same time triggered
112 # by inserting new elements.
113 # pylint: disable=C0301
114 'file://tough_animation_cases/css_animations_simultaneous_by_inserting_new_element.html?N=0316',
115 # Why: Tests many CSS Animations all starting at the same time triggered
116 # by inserting style sheets.
117 # pylint: disable=C0301
118 'file://tough_animation_cases/css_animations_simultaneous_by_inserting_style_element.html?N=0316',
119 # Why: Tests many CSS Animations all starting at the same time triggered
120 # by updating class.
121 # pylint: disable=C0301
122 'file://tough_animation_cases/css_animations_simultaneous_by_updating_class.html?N=0316',
123 # Why: Tests many CSS Animations all starting at the same time triggered
124 # by updating inline style.
125 # pylint: disable=C0301
126 'file://tough_animation_cases/css_animations_simultaneous_by_updating_inline_style.html?N=0316',
127 # Why: Tests many CSS Animations chained together using events at
128 # different times triggered by inserting new elements.
129 # pylint: disable=C0301
130 'file://tough_animation_cases/css_animations_staggered_chaining_by_inserting_new_element.html?N=0316',
131 # Why: Tests many CSS Animations chained together using events at
132 # different times triggered by inserting style sheets.
133 # pylint: disable=C0301
134 'file://tough_animation_cases/css_animations_staggered_chaining_by_inserting_style_element.html?N=0316',
135 # Why: Tests many CSS Animations chained together using events at
136 # different times triggered by updating class.
137 # pylint: disable=C0301
138 'file://tough_animation_cases/css_animations_staggered_chaining_by_updating_class.html?N=0316',
139 # Why: Tests many CSS Animations chained together using events at
140 # different times triggered by updating inline style.
141 # pylint: disable=C0301
142 'file://tough_animation_cases/css_animations_staggered_chaining_by_updating_inline_style.html?N=0316',
143 # Why: Tests many CSS Animations starting at different times triggered by
144 # inserting new elements.
145 # pylint: disable=C0301
146 'file://tough_animation_cases/css_animations_staggered_triggering_by_inserting_new_element.html?N=0316',
147 # Why: Tests many CSS Animations all starting at the same time with
148 # staggered animation offsets.
149 # pylint: disable=C0301
150 'file://tough_animation_cases/css_animations_staggered_infinite_iterations.html?N=0316',
151 # Why: Tests many CSS Animations starting at different times triggered by
152 # inserting style sheets.
153 # pylint: disable=C0301
154 'file://tough_animation_cases/css_animations_staggered_triggering_by_inserting_style_element.html?N=0316',
155 # Why: Tests many CSS Animations starting at different times triggered by
156 # updating class.
157 # pylint: disable=C0301
158 'file://tough_animation_cases/css_animations_staggered_triggering_by_updating_class.html?N=0316',
159 # Why: Tests many CSS Animations starting at different times triggered by
160 # updating inline style.
161 # pylint: disable=C0301
162 'file://tough_animation_cases/css_animations_staggered_triggering_by_updating_inline_style.html?N=0316',
164 # Why: Tests many Web Animations all starting at the same time with 500
165 # keyframes each.
166 'file://tough_animation_cases/web_animations_many_keyframes.html?N=0316',
167 # Why: Tests many paused Web Animations having their currentTimes updated
168 # in every requestAnimationFrame.
169 # pylint: disable=C0301
170 'file://tough_animation_cases/web_animations_set_current_time_in_raf.html?N=0316',
171 # Why: Tests many Web Animations all starting at the same time.
172 'file://tough_animation_cases/web_animations_simultaneous.html?N=0316',
173 # Why: Tests many Web Animations all starting at different times then
174 # chained together using events.
175 # pylint: disable=C0301
176 'file://tough_animation_cases/web_animations_staggered_chaining.html?N=0316',
177 # Why: Tests many Web Animations all starting at different times with
178 # infinite iterations.
179 # pylint: disable=C0301
180 'file://tough_animation_cases/web_animations_staggered_infinite_iterations.html?N=0316',
181 # Why: Tests many Web Animations all starting at different times.
182 # pylint: disable=C0301
183 'file://tough_animation_cases/web_animations_staggered_triggering.html?N=0316',
185 # Why: Tests color animations using CSS Animations.
186 # pylint: disable=C0301
187 'file://tough_animation_cases/css_value_type_color.html?api=css_animations&N=0316',
188 # Why: Tests filter animations using CSS Animations.
189 # pylint: disable=C0301
190 'file://tough_animation_cases/css_value_type_filter.html?api=css_animations&N=0316',
191 # Why: Tests length 3D animations using CSS Animations.
192 # pylint: disable=C0301
193 'file://tough_animation_cases/css_value_type_length_3d.html?api=css_animations&N=0316',
194 # Why: Tests complex length animations using CSS Animations.
195 # pylint: disable=C0301
196 'file://tough_animation_cases/css_value_type_length_complex.html?api=css_animations&N=0316',
197 # Why: Tests simple length animations using CSS Animations.
198 # pylint: disable=C0301
199 'file://tough_animation_cases/css_value_type_length_simple.html?api=css_animations&N=0316',
200 # Why: Tests shadow animations using CSS Animations.
201 # pylint: disable=C0301
202 'file://tough_animation_cases/css_value_type_shadow.html?api=css_animations&N=0316',
203 # Why: Tests complex transform animations using CSS Animations.
204 # pylint: disable=C0301
205 'file://tough_animation_cases/css_value_type_transform_complex.html?api=css_animations&N=0316',
206 # Why: Tests simple transform animations using CSS Animations.
207 # pylint: disable=C0301
208 'file://tough_animation_cases/css_value_type_transform_simple.html?api=css_animations&N=0316',
210 # Why: Tests color animations using Web Animations.
211 # pylint: disable=C0301
212 'file://tough_animation_cases/css_value_type_color.html?api=web_animations&N=0316',
213 # Why: Tests length 3D animations using Web Animations.
214 # pylint: disable=C0301
215 'file://tough_animation_cases/css_value_type_length_3d.html?api=web_animations&N=0316',
216 # Why: Tests complex length animations using Web Animations.
217 # pylint: disable=C0301
218 'file://tough_animation_cases/css_value_type_length_complex.html?api=web_animations&N=0316',
219 # Why: Tests simple length animations using Web Animations.
220 # pylint: disable=C0301
221 'file://tough_animation_cases/css_value_type_length_simple.html?api=web_animations&N=0316',
222 # Why: Tests shadow animations using Web Animations.
223 # pylint: disable=C0301
224 'file://tough_animation_cases/css_value_type_shadow.html?api=web_animations&N=0316',
225 # Why: Tests complex transform animations using Web Animations.
226 # pylint: disable=C0301
227 'file://tough_animation_cases/css_value_type_transform_complex.html?api=web_animations&N=0316',
228 # Why: Tests simple transform animations using Web Animations.
229 # pylint: disable=C0301
230 'file://tough_animation_cases/css_value_type_transform_simple.html?api=web_animations&N=0316',
233 for url in urls_list_one:
234 self.AddUserStory(ToughAnimationCasesPage(url, self,
235 need_measurement_ready=True))
237 urls_list_two = [
238 # Why: Tests various keyframed animations.
239 'file://tough_animation_cases/keyframed_animations.html',
240 # Why: Tests various transitions.
241 'file://tough_animation_cases/transform_transitions.html',
242 # Why: JS execution blocks CSS transition unless initial transform is set.
243 'file://tough_animation_cases/transform_transition_js_block.html'
245 # Disabled: crbug.com/350692
246 # Why: Login page is slow because of ineffecient transform operations.
247 # 'http://ie.microsoft.com/testdrive/performance/robohornetpro/',
250 for url in urls_list_two:
251 self.AddUserStory(ToughAnimationCasesPage(url, self,
252 need_measurement_ready=False))