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

Unified Diff: tools/perf/page_sets/tough_scheduling_cases.py

Issue 300413002: Add simple pepper plugin telemetry test (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 7 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/perf/page_sets/tough_scheduling_cases.py
diff --git a/tools/perf/page_sets/tough_scheduling_cases.py b/tools/perf/page_sets/tough_scheduling_cases.py
index 4cc5cb4f9e5330d67dad89046c019c67a89aeaca..e4708df4f0f47b3ef6bf329bc95e4736213cc1dd 100644
--- a/tools/perf/page_sets/tough_scheduling_cases.py
+++ b/tools/perf/page_sets/tough_scheduling_cases.py
@@ -318,6 +318,30 @@ class Page20(ToughSchedulingCasesPage):
'scroll_distance_function': 'function() { return 400; }'
}))
+class Page21(ToughSchedulingCasesPage):
+
+ """ Why: Simple pepper plugin for touch drawing """
+
+ def __init__(self, page_set):
+ super(Page21, self).__init__(
+ url='file://tough_scheduling_cases/simple_pepper_plugin.html',
+ page_set=page_set)
+
+ def RunSmoothness(self, action_runner):
+ # Wait until the page and the plugin module are loaded.
+ action_runner.RunAction(WaitAction(
+ {
+ 'javascript': ('pageLoaded === true && moduleLoaded === true')
+ }))
+ action_runner.RunAction(ScrollAction(
+ {
+ 'scroll_requires_touch': True,
+ 'direction': 'up',
+ 'top_start_percentage': 0.3,
+ 'speed': 200,
+ 'scroll_distance_function': 'function() { return 500; }',
+ }))
+
class EmptyTouchHandlerPage(ToughSchedulingCasesPage):
""" Why: Scrolling on a page with a touch handler that consumes no events but
@@ -403,6 +427,7 @@ class ToughSchedulingCasesPageSet(page_set_module.PageSet):
self.AddPage(Page18(self))
self.AddPage(Page19(self))
self.AddPage(Page20(self))
+ self.AddPage(Page21(self))
# Why: Baseline for scrolling in the presence of a no-op touch handler
self.AddPage(EmptyTouchHandlerPage(
name='baseline',
@@ -448,4 +473,3 @@ class ToughSchedulingCasesPageSet(page_set_module.PageSet):
slow_handler=True,
bounce=True,
page_set=self))
-

Powered by Google App Engine
This is Rietveld 408576698