Simplify the test harness
[WebKit-https.git] / PerformanceTests / Animometer / resources / debug-runner / tests.js
1 Utilities.extendObject(Headers, {
2     details: [
3         {
4             title: Strings.text.results.graph
5         },
6         {
7             title: Strings.text.experiments.complexity,
8             children:
9             [
10                 {
11                     text: function(data) {
12                         return data[Strings.json.experiments.complexity][Strings.json.measurements.average].toFixed(2);
13                     },
14                     className: "average"
15                 },
16                 {
17                     text: function(data) {
18                         return [
19                             "± ",
20                             data[Strings.json.experiments.complexity][Strings.json.measurements.percent].toFixed(2),
21                             "%"
22                         ].join("");
23                     },
24                     className: function(data) {
25                         var className = "stdev";
26
27                         if (data[Strings.json.experiments.complexity][Strings.json.measurements.percent] >= 10)
28                             className += " noisy-results";
29                         return className;
30                     }
31                 }
32             ]
33         },
34         {
35             title: Strings.text.experiments.frameRate,
36             children:
37             [
38                 {
39                     text: function(data) {
40                         return data[Strings.json.experiments.frameRate][Strings.json.measurements.average].toFixed(2);
41                     },
42                     className: function(data, options) {
43                         var className = "average";
44                         if (Math.abs(data[Strings.json.experiments.frameRate][Strings.json.measurements.average] - options["frame-rate"]) >= 2)
45                             className += " noisy-results";
46                         return className;
47                     }
48                 },
49                 {
50                     text: function(data) {
51                         var frameRateData = data[Strings.json.experiments.frameRate];
52                         return [
53                             "± ",
54                             frameRateData[Strings.json.measurements.percent].toFixed(2),
55                             "%"
56                         ].join("");
57                     },
58                     className: function(data) {
59                         var className = "stdev";
60
61                         if (data[Strings.json.experiments.frameRate][Strings.json.measurements.percent] >= 10)
62                             className += " noisy-results";
63                         return className;
64                     }
65                 }
66             ]
67         },
68     ]
69 })
70
71 ///////////
72 // Suites
73
74 Suites.push(new Suite("HTML suite",
75     [
76         {
77             url: "bouncing-particles/bouncing-css-shapes.html?particleWidth=12&particleHeight=12&shape=circle",
78             name: "CSS bouncing circles"
79         },
80         {
81             url: "bouncing-particles/bouncing-css-shapes.html?particleWidth=40&particleHeight=40&shape=rect&clip=star",
82             name: "CSS bouncing clipped rects"
83         },
84         {
85             url: "bouncing-particles/bouncing-css-shapes.html?particleWidth=50&particleHeight=50&shape=circle&fill=gradient",
86             name: "CSS bouncing gradient circles"
87         },
88         {
89             url: "bouncing-particles/bouncing-css-images.html?particleWidth=80&particleHeight=80&imageSrc=../resources/yin-yang.svg",
90             name: "CSS bouncing SVG images"
91         },
92         {
93             url: "bouncing-particles/bouncing-css-images.html?particleWidth=80&particleHeight=80&imageSrc=../resources/yin-yang.png",
94             name: "CSS bouncing PNG images"
95         },
96         {
97             url: "text/layering-text.html",
98             name: "CSS layering text"
99         },
100         {
101             url: "text/text-boxes.html?particleWidth=280&particleHeight=180",
102             name: "CSS text boxes"
103         },
104     ]
105 ));
106
107 Suites.push(new Suite("Canvas suite",
108     [
109         {
110             url: "bouncing-particles/bouncing-canvas-shapes.html?particleWidth=12&particleHeight=12&shape=circle",
111             name: "canvas bouncing circles"
112         },
113         {
114             url: "bouncing-particles/bouncing-canvas-shapes.html?particleWidth=40&particleHeight=40&shape=rect&clip=star",
115             name: "canvas bouncing clipped rects"
116         },
117         {
118             url: "bouncing-particles/bouncing-canvas-shapes.html?particleWidth=50&particleHeight=50&shape=circle&fill=gradient",
119             name: "canvas bouncing gradient circles"
120         },
121         {
122             url: "bouncing-particles/bouncing-canvas-images.html?particleWidth=80&particleHeight=80&imageSrc=../resources/yin-yang.svg",
123             name: "canvas bouncing SVG images"
124         },
125         {
126             url: "bouncing-particles/bouncing-canvas-images.html?particleWidth=80&particleHeight=80&imageSrc=../resources/yin-yang.png",
127             name: "canvas bouncing PNG images"
128         },
129     ]
130 ));
131
132 Suites.push(new Suite("SVG suite",
133     [
134         {
135             url: "bouncing-particles/bouncing-svg-shapes.html?particleWidth=12&particleHeight=12&shape=circle",
136             name: "SVG bouncing circles",
137         },
138         {
139             url: "bouncing-particles/bouncing-svg-shapes.html?particleWidth=40&particleHeight=40&shape=rect&clip=star",
140             name: "SVG bouncing clipped rects",
141         },
142         {
143             url: "bouncing-particles/bouncing-svg-shapes.html?particleWidth=50&particleHeight=50&shape=circle&fill=gradient",
144             name: "SVG bouncing gradient circles"
145         },
146         {
147             url: "bouncing-particles/bouncing-svg-images.html?particleWidth=80&particleHeight=80&imageSrc=../resources/yin-yang.svg",
148             name: "SVG bouncing SVG images"
149         },
150         {
151             url: "bouncing-particles/bouncing-svg-images.html?particleWidth=80&particleHeight=80&imageSrc=../resources/yin-yang.png",
152             name: "SVG bouncing PNG images"
153         },
154     ]
155 ));
156
157 Suites.push(new Suite("Basic canvas path suite",
158     [
159         {
160             url: "simple/simple-canvas-paths.html?pathType=line&lineCap=butt",
161             name: "Canvas line segments, butt caps"
162         },
163         {
164             url: "simple/simple-canvas-paths.html?pathType=line&lineCap=round",
165             name: "Canvas line segments, round caps"
166         },
167         {
168             url: "simple/simple-canvas-paths.html?pathType=line&lineCap=square",
169             name: "Canvas line segments, square caps"
170         },
171         {
172             url: "simple/simple-canvas-paths.html?pathType=linePath&lineJoin=bevel",
173             name: "Canvas line path, bevel join"
174         },
175         {
176             url: "simple/simple-canvas-paths.html?pathType=linePath&lineJoin=round",
177             name: "Canvas line path, round join"
178         },
179         {
180             url: "simple/simple-canvas-paths.html?pathType=linePath&lineJoin=miter",
181             name: "Canvas line path, miter join"
182         },
183         {
184             url: "simple/simple-canvas-paths.html?pathType=linePath&lineDash=1",
185             name: "Canvas line path with dash pattern"
186         },
187         {
188             url: "simple/simple-canvas-paths.html?pathType=quadratic",
189             name: "Canvas quadratic segments"
190         },
191         {
192             url: "simple/simple-canvas-paths.html?pathType=quadraticPath",
193             name: "Canvas quadratic path"
194         },
195         {
196             url: "simple/simple-canvas-paths.html?pathType=bezier",
197             name: "Canvas bezier segments"
198         },
199         {
200             url: "simple/simple-canvas-paths.html?pathType=bezierPath",
201             name: "Canvas bezier path"
202         },
203         {
204             url: "simple/simple-canvas-paths.html?&pathType=arcTo",
205             name: "Canvas arcTo segments"
206         },
207         {
208             url: "simple/simple-canvas-paths.html?pathType=arc",
209             name: "Canvas arc segments"
210         },
211         {
212             url: "simple/simple-canvas-paths.html?pathType=rect",
213             name: "Canvas rects"
214         },
215         {
216             url: "simple/simple-canvas-paths.html?pathType=lineFill",
217             name: "Canvas line path, fill"
218         },
219         {
220             url: "simple/simple-canvas-paths.html?pathType=quadraticFill",
221             name: "Canvas quadratic path, fill"
222         },
223         {
224             url: "simple/simple-canvas-paths.html?pathType=bezierFill",
225             name: "Canvas bezier path, fill"
226         },
227         {
228             url: "simple/simple-canvas-paths.html?&pathType=arcToFill",
229             name: "Canvas arcTo segments, fill"
230         },
231         {
232             url: "simple/simple-canvas-paths.html?pathType=arcFill",
233             name: "Canvas arc segments, fill"
234         },
235         {
236             url: "simple/simple-canvas-paths.html?pathType=rectFill",
237             name: "Canvas rects, fill"
238         }
239     ]
240 ));
241
242 Suites.push(new Suite("Miscellaneous Tests",
243     [
244         {
245             url: "misc/compositing-transforms.html?particleWidth=50&particleHeight=50&filters=yes&imageSrc=../resources/yin-yang.svg",
246             name: "Composited Transforms"
247         },
248         {
249             url: "misc/canvas-electrons.html",
250             name: "Canvas electrons"
251         },
252         {
253             url: "misc/canvas-stars.html",
254             name: "Canvas stars"
255         },
256     ]
257 ));