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

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

Issue 18576004: [telemetry] Add @RunOnBuildMastersNamed support (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 7 years, 5 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 (c) 2013 The Chromium Authors. All rights reserved. 1 # Copyright (c) 2013 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 collections 4 import collections
5 import json 5 import json
6 import os 6 import os
7 7
8 from telemetry import test 8 from telemetry import test
9 from telemetry.core import util 9 from telemetry.core import util
10 from telemetry.page import page_measurement 10 from telemetry.page import page_measurement
(...skipping 19 matching lines...) Expand all
30 total = 0 30 total = 0
31 for key, value in result.iteritems(): 31 for key, value in result.iteritems():
32 r[key].append(value) 32 r[key].append(value)
33 total += value 33 total += value
34 totals.append(total) 34 totals.append(total)
35 for key, values in r.iteritems(): 35 for key, values in r.iteritems():
36 results.Add(key, 'ms', values, data_type='unimportant') 36 results.Add(key, 'ms', values, data_type='unimportant')
37 results.Add('Total', 'ms', totals) 37 results.Add('Total', 'ms', totals)
38 38
39 39
40 @test.RunOnBuildMastersNamed('chromium.perf')
40 class Sunspider(test.Test): 41 class Sunspider(test.Test):
41 """Performance on Apple's SunSpider JavaScript benchmark""" 42 """Performance on Apple's SunSpider JavaScript benchmark"""
42 test = SunspiderMeasurement 43 test = SunspiderMeasurement
43 44
44 def CreatePageSet(self, options): 45 def CreatePageSet(self, options):
45 sunspider_dir = os.path.join(util.GetChromiumSrcDir(), 46 sunspider_dir = os.path.join(util.GetChromiumSrcDir(),
46 'chrome', 'test', 'data', 'sunspider') 47 'chrome', 'test', 'data', 'sunspider')
47 return page_set.PageSet.FromDict( 48 return page_set.PageSet.FromDict(
48 { 49 {
49 'serving_dirs': [''], 50 'serving_dirs': [''],
50 'pages': [{ 'url': 'file:///sunspider-1.0/driver.html' }], 51 'pages': [{ 'url': 'file:///sunspider-1.0/driver.html' }],
51 }, 52 },
52 sunspider_dir) 53 sunspider_dir)
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698