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

Side by Side Diff: tools/perf/benchmarks/start_with_url.py

Issue 816353008: [Telemetry] Explicitly define Name() method for all perf benchmarks (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 11 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 4
5 from measurements import startup 5 from measurements import startup
6 import page_sets 6 import page_sets
7 from telemetry import benchmark 7 from telemetry import benchmark
8 8
9 9
10 class _StartWithUrl(benchmark.Benchmark): 10 class _StartWithUrl(benchmark.Benchmark):
11 page_set = page_sets.StartupPagesPageSet 11 page_set = page_sets.StartupPagesPageSet
12 test = startup.StartWithUrl 12 test = startup.StartWithUrl
13 13
14 @classmethod
15 def Name(cls):
16 return 'start_with_url.startup_pages'
17
14 def CreatePageTest(self, options): 18 def CreatePageTest(self, options):
15 is_cold = (self.tag == 'cold') 19 is_cold = (self.tag == 'cold')
16 return self.test(cold=is_cold) 20 return self.test(cold=is_cold)
17 21
18 22
19 @benchmark.Enabled('has tabs') 23 @benchmark.Enabled('has tabs')
20 @benchmark.Disabled('chromeos', 'linux', 'mac', 'win') 24 @benchmark.Disabled('chromeos', 'linux', 'mac', 'win')
21 class StartWithUrlCold(_StartWithUrl): 25 class StartWithUrlCold(_StartWithUrl):
22 """Measure time to start Chrome cold with startup URLs""" 26 """Measure time to start Chrome cold with startup URLs"""
23 tag = 'cold' 27 tag = 'cold'
24 options = {'pageset_repeat': 5} 28 options = {'pageset_repeat': 5}
25 29
30 @classmethod
31 def Name(cls):
32 return 'start_with_url.cold.startup_pages'
33
26 34
27 @benchmark.Enabled('has tabs') 35 @benchmark.Enabled('has tabs')
28 @benchmark.Disabled('chromeos', 'linux', 'mac', 'win') 36 @benchmark.Disabled('chromeos', 'linux', 'mac', 'win')
29 class StartWithUrlWarm(_StartWithUrl): 37 class StartWithUrlWarm(_StartWithUrl):
30 """Measure time to start Chrome warm with startup URLs""" 38 """Measure time to start Chrome warm with startup URLs"""
31 tag = 'warm' 39 tag = 'warm'
32 options = {'pageset_repeat': 10} 40 options = {'pageset_repeat': 10}
41 @classmethod
42 def Name(cls):
43 return 'start_with_url.warm.startup_pages'
44
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698