summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorojan@chromium.org <ojan@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-09-23 00:27:52 +0000
committerojan@chromium.org <ojan@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-09-23 00:27:52 +0000
commit8cd7d69565a1f4f9dfae797b8cd25bf18292a423 (patch)
treed9c8c9c960b2f2533a21ed7d841f4ec47a842f27
parentd5db4da35c9922d39265a7836bd0357cc8603e80 (diff)
downloadchromium_src-8cd7d69565a1f4f9dfae797b8cd25bf18292a423.zip
chromium_src-8cd7d69565a1f4f9dfae797b8cd25bf18292a423.tar.gz
chromium_src-8cd7d69565a1f4f9dfae797b8cd25bf18292a423.tar.bz2
Fix up aggregate dashboard to use the new data. The only thing missing now is
the number of skipped results on sharded builders. This has been true forever. I'll have a partial fix for that in a separate change. This time, the data format is really done and ready to be turned into pretty graphs. The data for each row in this table is created as an array, then getHTMLForTableRow is called. The graph version of this should be able to just rewrite getHTMLForTableRow to use canvas instead. Review URL: http://codereview.chromium.org/208062 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@26885 0039d316-1c4b-4281-b951-d872f2087c98
-rw-r--r--webkit/tools/layout_tests/dashboards/aggregate_results.html74
-rw-r--r--webkit/tools/layout_tests/dashboards/dashboard_base.js11
2 files changed, 57 insertions, 28 deletions
diff --git a/webkit/tools/layout_tests/dashboards/aggregate_results.html b/webkit/tools/layout_tests/dashboards/aggregate_results.html
index 6cf9c17..8b1710c 100644
--- a/webkit/tools/layout_tests/dashboards/aggregate_results.html
+++ b/webkit/tools/layout_tests/dashboards/aggregate_results.html
@@ -42,47 +42,75 @@
function getHTMLForBuilder(builder) {
var results = resultsByBuilder[builder];
+ // Some keys were added later than others, so they don't have as many
+ // builds. Use the shortest.
+ // TODO(ojan): Once 500 runs have finished, we can get rid of passing this
+ // around and just assume all keys have the same number of builders for a
+ // given builder.
+ var numColumns = results[ALL_FIXABLE_COUNT_KEY].length;
return '<div class=container><h2>' + builder + '</h2>' +
- getHTMLForTestType(results, NON_WONTFIX_COUNTS_KEY,
- NON_WONTFIX_DESCRIPTION) +
- getHTMLForTestType(results, DEFERRED_COUNTS_KEY, DEFERRED_DESCRIPTION) +
- getHTMLForTestType(results, ALL_COUNTS_KEY, ALL_COUNTS_DESCRIPTION) +
- '</div>';
+ getHTMLForSummaryTable(results, numColumns) +
+ getHTMLForTestType(results, FIXABLE_COUNTS_KEY, FIXABLE_DESCRIPTION,
+ numColumns) +
+ getHTMLForTestType(results, DEFERRED_COUNTS_KEY, DEFERRED_DESCRIPTION,
+ numColumns) +
+ getHTMLForTestType(results, WONTFIX_COUNTS_KEY, WONTFIX_DESCRIPTION,
+ numColumns) + '</div>';
}
- function getHTMLForTestType(results, key, description) {
+ function getHTMLForRevisionRows(results, numColumns) {
+ return getHTMLForTableRow('WebKit Revision',
+ results[WEBKIT_REVISIONS_KEY].slice(0, numColumns)) +
+ getHTMLForTableRow('Chrome Revision',
+ results[CHROME_REVISIONS_KEY].slice(0, numColumns));
+ }
+
+ function wrapHTMLInTable(description, html) {
+ return '<h3>' + description + '</h3><table><tbody>' + html +
+ '</tbody></table>';
+ }
+
+ function getHTMLForSummaryTable(results, numColumns) {
+ var percent = [];
+ var fixable = results[FIXABLE_COUNT_KEY].slice(0, numColumns);
+ var allFixable = results[ALL_FIXABLE_COUNT_KEY].slice(0, numColumns);
+ for (var i = 0; i < numColumns; i++) {
+ var percentage = 100 * (allFixable[i] - fixable[i]) / allFixable[i];
+ // Round to the nearest tenth of a percent.
+ percent.push(Math.round(percentage * 10) / 10 + '%');
+ }
+ var html = getHTMLForRevisionRows(results, numColumns) +
+ getHTMLForTableRow('Percent passed', percent) +
+ getHTMLForTableRow('Failures (deduped)', fixable) +
+ getHTMLForTableRow('Fixable Tests', allFixable);
+ return wrapHTMLInTable('Summary', html);
+ }
+
+ function getHTMLForTestType(results, key, description, numColumns) {
// TODO(dglazkov): Make these pretty canvasy graphs.
- var html = '<h3>' + description + '</h3><table><tbody>';
var counts = results[key];
+ var html = getHTMLForRevisionRows(results, numColumns);
- var numColumns = counts.length;
- html += getHTMLForTableRow('WebKit Revision',
- results[WEBKIT_REVISIONS_KEY].slice(0, numColumns));
- html += getHTMLForTableRow('Chrome Revision',
- results[CHROME_REVISIONS_KEY].slice(0, numColumns));
- html += getHTMLForTableRow('Failures (deduped)',
- results[FIXABLE_COUNT_KEY].slice(0, numColumns));
-
- var htmlForEachRow = {};
- for (var i = 0; i < counts.length; i++) {
+ var valuesForEachRow = {};
+ for (var i = 0; i < numColumns; i++) {
for (var expectation in EXPECTATIONS_MAP) {
if (expectation in counts[i]) {
var count = counts[i][expectation];
- if (!htmlForEachRow[expectation])
- htmlForEachRow[expectation] = [];
+ if (!valuesForEachRow[expectation])
+ valuesForEachRow[expectation] = [];
- htmlForEachRow[expectation].push(count);
+ valuesForEachRow[expectation].push(count);
}
}
}
- for (var expectation in htmlForEachRow) {
+ for (var expectation in valuesForEachRow) {
html += getHTMLForTableRow(EXPECTATIONS_MAP[expectation],
- htmlForEachRow[expectation]);
+ valuesForEachRow[expectation]);
}
- return html + '</tbody></table>';
+ return wrapHTMLInTable(description, html);
}
function getHTMLForTableRow(columnName, values) {
diff --git a/webkit/tools/layout_tests/dashboards/dashboard_base.js b/webkit/tools/layout_tests/dashboards/dashboard_base.js
index b659286..40e31d5 100644
--- a/webkit/tools/layout_tests/dashboards/dashboard_base.js
+++ b/webkit/tools/layout_tests/dashboards/dashboard_base.js
@@ -48,13 +48,14 @@ var EXPECTATIONS_MAP = {
};
// Keys in the JSON files.
-var NON_WONTFIX_COUNTS_KEY = 'nonWontfixCounts';
-var ALL_COUNTS_KEY = 'allCounts';
+var WONTFIX_COUNTS_KEY = 'wontfixCounts';
+var FIXABLE_COUNTS_KEY = 'fixableCounts';
var DEFERRED_COUNTS_KEY = 'deferredCounts';
-var NON_WONTFIX_DESCRIPTION = 'All tests we want to pass for this release';
-var ALL_COUNTS_DESCRIPTION = 'All tests (inludes WONTFIX)';
-var DEFERRED_DESCRIPTION = 'All deferred tests';
+var WONTFIX_DESCRIPTION = 'Tests never to be fixed (WONTFIX)';
+var FIXABLE_DESCRIPTION = 'All tests for this release';
+var DEFERRED_DESCRIPTION = 'All deferred tests (DEFER)';
var FIXABLE_COUNT_KEY = 'fixableCount';
+var ALL_FIXABLE_COUNT_KEY = 'allFixableCount';
var CHROME_REVISIONS_KEY = 'chromeRevision';
var WEBKIT_REVISIONS_KEY = 'webkitRevision';