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

Side by Side Diff: LayoutTests/fast/harness/archived-results-dashboard.html

Issue 339623002: Added support for versioning of layout test results of run-webkit-tests runs (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Added layout test Created 6 years, 4 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
« no previous file with comments | « no previous file | LayoutTests/fast/harness/archived-results-dashboard-expected.txt » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
(Empty)
1 <!DOCTYPE html>
2 <style>
3 html {
4 height: 100%;
5 }
6 body {
7 margin: 0;
8 font-family: Helvetica, sans-serif;
9 font-size: 11pt;
10 display: -webkit-flex;
11 -webkit-flex-direction: column;
12 height: 100%;
13 }
14
15 body > * {
16 margin-left: 4px;
17 margin-top: 4px;
18 }
19
20 h1 {
21 font-size: 14pt;
22 margin-top: 1.5em;
23 text-align: center;
24 text-decoration: underline;
25 }
26
27 a {
28 text-decoration: none;
29 }
30
31 tr {
32 background-color: white;
33 }
34
35 tr:hover {
36 background-color: #999999;
37 }
38
39 td {
40 padding: 1px 4px;
41 valign: center;
42 }
43
44 td:hover .note{
45 display: block;
46 }
47
48 .test-pass {
49 background-color:rgb(0,255,0);
50 }
51
52 .test-fail {
53 background-color:rgb(255,0,0);
54 }
55
56 .test-skip {
57 background-color:rgb(255,255,255);
58 }
59 </style>
60 <script>
61 var g_state;
62 function globalState()
63 {
64 if (!g_state) {
65 g_state = {
66 results: {}
67 }
68 }
69 return g_state;
70 }
71
72 function ADD_RESULTS(input)
73 {
74 globalState().results = input;
75 }
76 </script>
77 <script src="archived_results.json"></script>
78 <script>
79 function processGlobalStateFor(testObject)
80 {
81 var table = document.getElementById('results-table');
82 var row = table.insertRow(-1);
83 var cell = row.insertCell(-1);
84 cell.innerHTML = testObject.name;
85 for (var result in testObject.archived_results) {
86 var res = testObject.archived_results[result];
87 var cell = row.insertCell(-1);
88 if( res == 'PASS')
89 cell.className = 'test-pass';
90 else if( res == 'SKIP')
91 cell.className = 'test-skip';
92 else
93 cell.className = 'test-fail';
94 var hrefElement = document.createElement("a");
95 hrefElement.href = globalState().results.result_links[result];
96 hrefElement.innerHTML = '&nbsp;&nbsp;';
97 cell.appendChild(hrefElement);
98 }
99
100
101 }
102 function forEachTest(handler, opt_tree, opt_prefix)
103 {
104 var tree = opt_tree || globalState().results.tests;
105 var prefix = opt_prefix || '';
106
107 for (var key in tree) {
108 var newPrefix = prefix ? (prefix + '/' + key) : key;
109 if ('archived_results' in tree[key]) {
110 var testObject = tree[key];
111 testObject.name = newPrefix;
112 handler(testObject);
113 } else
114 forEachTest(handler, tree[key], newPrefix);
115 }
116 }
117 function generatePage()
118 {
119 var count = globalState().results.result_links.length;
120 var tableHeader= '<div><table id= results-table><thead><tr>' +
121 '<th>Failing Tests ( Latest &#8594; Oldest )</th>';
122 for( var i = 0; i < count; i++)
123 tableHeader += '<th>'+ (i+1) +'</th>';
124 tableHeader += '</thead>';
125 document.body.innerHTML += tableHeader;
126 document.body.innerHTML += '</table></div>';
127
128 forEachTest(processGlobalStateFor);
129 }
130 </script>
131 <!-- To run the tests -->
132 <script src="resources/archived-results-dashboard-test.js"></script>
133 <body onload="generatePage()"><h1>Dashboard</h1></body>
134 </html>
OLDNEW
« no previous file with comments | « no previous file | LayoutTests/fast/harness/archived-results-dashboard-expected.txt » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698