Botwatcher's Dashboard is cramped
authordburkart@apple.com <dburkart@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 5 Feb 2015 00:37:36 +0000 (00:37 +0000)
committerdburkart@apple.com <dburkart@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 5 Feb 2015 00:37:36 +0000 (00:37 +0000)
https://bugs.webkit.org/show_bug.cgi?id=140273

Reviewed by Alexey Proskuryakov.

Add a heading key which will allow for arbitrary headings in builder queues.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@179650 268f45cc-cd09-0410-ab3c-d52691b4dbfc

Tools/BuildSlaveSupport/build.webkit.org-config/public_html/dashboard/Scripts/BuildbotBuilderQueueView.js
Tools/BuildSlaveSupport/build.webkit.org-config/public_html/dashboard/Scripts/BuildbotIteration.js
Tools/BuildSlaveSupport/build.webkit.org-config/public_html/dashboard/Scripts/BuildbotLeaksQueueView.js
Tools/BuildSlaveSupport/build.webkit.org-config/public_html/dashboard/Scripts/BuildbotPerformanceQueueView.js
Tools/BuildSlaveSupport/build.webkit.org-config/public_html/dashboard/Scripts/BuildbotQueue.js
Tools/BuildSlaveSupport/build.webkit.org-config/public_html/dashboard/Scripts/BuildbotQueueView.js
Tools/BuildSlaveSupport/build.webkit.org-config/public_html/dashboard/Scripts/BuildbotTestResults.js
Tools/BuildSlaveSupport/build.webkit.org-config/public_html/dashboard/Scripts/BuildbotTesterQueueView.js
Tools/ChangeLog

index 5a5047c..9c77ad4 100644 (file)
@@ -103,7 +103,7 @@ BuildbotBuilderQueueView.prototype = {
                 var status = new StatusLineView(message, StatusLineView.Status.Good, firstRecentUnsuccessfulIteration ? "last successful build" : "latest build", null, url);
                 this.element.appendChild(status.element);
             } else {
-                var status = new StatusLineView("unknown", StatusLineView.Status.Neutral, firstRecentUnsuccessfulIteration ? "last successful build" : "latest build");            
+                var status = new StatusLineView("unknown", StatusLineView.Status.Neutral, firstRecentUnsuccessfulIteration ? "last successful build" : "latest build");
                 this.element.appendChild(status.element);
 
                 if (firstRecentUnsuccessfulIteration) {
@@ -113,27 +113,13 @@ BuildbotBuilderQueueView.prototype = {
             }
         }
 
-        function appendBuildArchitecture(queues, label)
-        {
-            queues.forEach(function(queue) {
-                var releaseLabel = document.createElement("a");
-                releaseLabel.classList.add("queueLabel");
-                releaseLabel.textContent = label;
-                releaseLabel.href = queue.overviewURL;
-                releaseLabel.target = "_blank";
-                this.element.appendChild(releaseLabel);
-
-                appendBuilderQueueStatus.call(this, queue);
-            }.bind(this));
-        }
-
-        appendBuildArchitecture.call(this, this.universalReleaseQueues, this.hasMultipleReleaseBuilds ? "Release (Universal)" : "Release");
-        appendBuildArchitecture.call(this, this.sixtyFourBitReleaseQueues, this.hasMultipleReleaseBuilds ? "Release (64-bit)" : "Release");
-        appendBuildArchitecture.call(this, this.thirtyTwoBitReleaseQueues, this.hasMultipleReleaseBuilds ? "Release (32-bit)" : "Release");
+        this.appendBuildStyle.call(this, this.universalReleaseQueues, this.hasMultipleReleaseBuilds ? "Release (Universal)" : "Release", appendBuilderQueueStatus);
+        this.appendBuildStyle.call(this, this.sixtyFourBitReleaseQueues, this.hasMultipleReleaseBuilds ? "Release (64-bit)" : "Release", appendBuilderQueueStatus);
+        this.appendBuildStyle.call(this, this.thirtyTwoBitReleaseQueues, this.hasMultipleReleaseBuilds ? "Release (32-bit)" : "Release", appendBuilderQueueStatus);
 
-        appendBuildArchitecture.call(this, this.universalDebugQueues, this.hasMultipleDebugBuilds ? "Debug (Universal)" : "Debug");
-        appendBuildArchitecture.call(this, this.sixtyFourBitDebugQueues, this.hasMultipleDebugBuilds ? "Debug (64-bit)" : "Debug");
-        appendBuildArchitecture.call(this, this.thirtyTwoBitDebugQueues, this.hasMultipleDebugBuilds ? "Debug (32-bit)" : "Debug");
+        this.appendBuildStyle.call(this, this.universalDebugQueues, this.hasMultipleDebugBuilds ? "Debug (Universal)" : "Debug", appendBuilderQueueStatus);
+        this.appendBuildStyle.call(this, this.sixtyFourBitDebugQueues, this.hasMultipleDebugBuilds ? "Debug (64-bit)" : "Debug", appendBuilderQueueStatus);
+        this.appendBuildStyle.call(this, this.thirtyTwoBitDebugQueues, this.hasMultipleDebugBuilds ? "Debug (32-bit)" : "Debug", appendBuilderQueueStatus);
     },
 
     _presentPopoverFailureLogs: function(element, popover, iteration)
index e0b3df6..778cc0f 100644 (file)
@@ -227,6 +227,7 @@ BuildbotIteration.prototype = {
             testResults.uniqueLeakCount = testStep.results[1].reduce(resultSummarizer.bind(null, "unique leak"), undefined);
             testResults.newPassesCount = testStep.results[1].reduce(resultSummarizer.bind(null, "new pass"), undefined);
             testResults.missingCount = testStep.results[1].reduce(resultSummarizer.bind(null, "missing"), undefined);
+            testResults.crashCount = testStep.results[1].reduce(resultSummarizer.bind(null, "crash"), undefined);
 
             if (!testResults.failureCount && !testResults.flakyCount && !testResults.totalLeakCount && !testResults.uniqueLeakCount && !testResults.newPassesCount && !testResults.missingCount) {
                 // This step exited with a non-zero exit status, but we didn't find any output about the number of failed tests.
index a2e4db4..50756b8 100644 (file)
@@ -84,21 +84,7 @@ BuildbotLeaksQueueView.prototype = {
             new PopoverTracker(status.statusBubbleElement, this._presentPopoverForLeaksQueue.bind(this), iteration);
         }
 
-        function appendBuild(queues, label)
-        {
-            queues.forEach(function(queue) {
-                var releaseLabel = document.createElement("a");
-                releaseLabel.classList.add("queueLabel");
-                releaseLabel.textContent = queue.LeaksTestName ? queue.LeaksTestName : label;
-                releaseLabel.href = queue.overviewURL;
-                releaseLabel.target = "_blank";
-                this.element.appendChild(releaseLabel);
-
-                appendLeaksQueueStatus.call(this, queue);
-            }.bind(this));
-        }
-
-        appendBuild.call(this, this.releaseQueues, "Leaks");
+        this.appendBuildStyle.call(this, this.releaseQueues, "Leaks", appendLeaksQueueStatus);
     },
 
     addLinkToRow: function(rowElement, className, text, url)
index a8f4d4a..217cd0b 100644 (file)
@@ -82,21 +82,7 @@ BuildbotPerformanceQueueView.prototype = {
             new PopoverTracker(status.statusBubbleElement, this._presentPopoverForPerformanceQueue.bind(this), queue);
         }
 
-        function appendBuild(queues, label)
-        {
-            queues.forEach(function(queue) {
-                var releaseLabel = document.createElement("a");
-                releaseLabel.classList.add("queueLabel");
-                releaseLabel.textContent = queue.performanceTestName ? queue.performanceTestName : label;
-                releaseLabel.href = queue.overviewURL;
-                releaseLabel.target = "_blank";
-                this.element.appendChild(releaseLabel);
-
-                appendPerformanceQueueStatus.call(this, queue);
-            }.bind(this));
-        }
-
-        appendBuild.call(this, this.releaseQueues, 'Release');
+        this.appendBuildStyle.call(this, this.releaseQueues, 'Release', appendPerformanceQueueStatus);
     },
 
     addLinkToRow: function(rowElement, className, text, url)
index 2317c08..72d305e 100644 (file)
@@ -42,7 +42,8 @@ BuildbotQueue = function(buildbot, id, info)
     this.leaks = info.leaks || false;
     this.architecture = info.architecture || null;
     this.testCategory = info.testCategory || null;
-    this.performanceTestName = info.performanceTestName || null;
+    this.heading = info.heading || null;
+    this.crashesOnly = info.crashesOnly || false;
 
     this.iterations = [];
     this._knownIterations = {};
index 7e4be8b..c38c716 100644 (file)
@@ -286,6 +286,20 @@ BuildbotQueueView.prototype = {
         return fragment;
     },
 
+    appendBuildStyle: function(queues, defaultLabel, appendFunction)
+    {
+        queues.forEach(function(queue) {
+            var releaseLabel = document.createElement("a");
+            releaseLabel.classList.add("queueLabel");
+            releaseLabel.textContent = queue.heading ? queue.heading : defaultLabel;
+            releaseLabel.href = queue.overviewURL;
+            releaseLabel.target = "_blank";
+            this.element.appendChild(releaseLabel);
+
+            appendFunction.call(this, queue);
+        }.bind(this));
+    },
+
     _updateQueues: function()
     {
         this.releaseQueues.forEach(function(queue) { queue.update(); });
@@ -316,4 +330,5 @@ BuildbotQueueView.prototype = {
     {
         this.updateSoon();
     }
+
 };
index ce69c86..bb42c9d 100644 (file)
@@ -39,6 +39,7 @@ BuildbotTestResults = function(buildbotIteration, info)
     this.uniqueLeakCount = info.uniqueLeakCount || 0;
     this.newPassesCount = info.newPassesCount || 0;
     this.missingCount = info.missingCount || 0;
+    this.crashCount = info.crashCount || 0;
 };
 
 BaseObject.addConstructorFunctions(BuildbotTestResults);
index ba5273a..523fb4f 100644 (file)
@@ -79,6 +79,13 @@ BuildbotTesterQueueView.prototype = {
                 } else if (!iteration.productive) {
                     var url = iteration.queue.buildbot.buildPageURLForIteration(iteration);
                     var status = new StatusLineView(messageElement, StatusLineView.Status.Danger, iteration.text, undefined, url);
+                } else if (queue.crashesOnly && !iteration.crashCount) {
+                    var url = iteration.queue.buildbot.buildPageURLForIteration(iteration);
+                    var status = new StatusLineView(messageElement, StatusLineView.Status.Good, "no crashes found", undefined, url);
+                } else if (queue.crashesOnly && iteration.crashCount) {
+                    var url = iteration.queue.buildbot.layoutTestResultsURLForIteration(iteration);
+                    var status = new StatusLineView(messageElement, StatusLineView.Status.Bad, layoutTestResults.failureCount === 1 ? "crash found" : "crashes found", undefined, url);
+                    new PopoverTracker(status.statusBubbleElement, this._presentPopoverForLayoutTestRegressions.bind(this), iteration);
                 } else if (!layoutTestResults.failureCount && !javascriptTestResults.failureCount && !apiTestResults.failureCount && !platformAPITestResults.failureCount && !pythonTestResults.failureCount && !perlTestResults.errorOccurred && !bindingTestResults.errorOccurred) {
                     // Something wrong happened, but it was not a test failure.
                     var url = iteration.queue.buildbot.buildPageURLForIteration(iteration);
@@ -122,22 +129,8 @@ BuildbotTesterQueueView.prototype = {
             }
         }
 
-        function appendBuild(queues, label)
-        {
-            queues.forEach(function(queue) {
-                var releaseLabel = document.createElement("a");
-                releaseLabel.classList.add("queueLabel");
-                releaseLabel.textContent = label;
-                releaseLabel.href = queue.overviewURL;
-                releaseLabel.target = "_blank";
-                this.element.appendChild(releaseLabel);
-
-                appendBuilderQueueStatus.call(this, queue);
-            }.bind(this));
-        }
-
-        appendBuild.call(this, this.releaseQueues, "Release");
-        appendBuild.call(this, this.debugQueues, "Debug");
+        this.appendBuildStyle.call(this, this.releaseQueues, "Release", appendBuilderQueueStatus);
+        this.appendBuildStyle.call(this, this.debugQueues, "Debug", appendBuilderQueueStatus);
     },
 
     _popoverContentForLayoutTestRegressions: function(iteration)
index 13524f6..4e1b01d 100644 (file)
@@ -1,3 +1,36 @@
+2015-02-04  Dana Burkart  <dburkart@apple.com>
+
+        Botwatcher's Dashboard is cramped
+        https://bugs.webkit.org/show_bug.cgi?id=140273
+
+        Reviewed by Alexey Proskuryakov.
+
+        Add a heading key which will allow for arbitrary headings in builder queues.
+
+        * BuildSlaveSupport/build.webkit.org-config/public_html/dashboard/Scripts/BuildbotBuilderQueueView.js:
+        (BuildbotBuilderQueueView.prototype.update.appendBuilderQueueStatus):
+        (BuildbotBuilderQueueView.prototype.update):
+        (BuildbotBuilderQueueView.prototype.update.appendBuildArchitecture): Deleted.
+        * BuildSlaveSupport/build.webkit.org-config/public_html/dashboard/Scripts/BuildbotIteration.js:
+        (BuildbotIteration.prototype._parseData):
+        * BuildSlaveSupport/build.webkit.org-config/public_html/dashboard/Scripts/BuildbotLeaksQueueView.js:
+        (BuildbotLeaksQueueView.prototype.update):
+        (BuildbotLeaksQueueView.prototype.update.appendBuild): Deleted.
+        * BuildSlaveSupport/build.webkit.org-config/public_html/dashboard/Scripts/BuildbotPerformanceQueueView.js:
+        (BuildbotPerformanceQueueView.prototype.update):
+        (BuildbotPerformanceQueueView.prototype.update.appendBuild): Deleted.
+        * BuildSlaveSupport/build.webkit.org-config/public_html/dashboard/Scripts/BuildbotQueue.js:
+        (BuildbotQueue):
+        * BuildSlaveSupport/build.webkit.org-config/public_html/dashboard/Scripts/BuildbotQueueView.js:
+        (BuildbotQueueView.prototype._unauthorizedAccess):
+        (BuildbotQueueView.prototype._appendBuild):
+        * BuildSlaveSupport/build.webkit.org-config/public_html/dashboard/Scripts/BuildbotTestResults.js:
+        (BuildbotTestResults):
+        * BuildSlaveSupport/build.webkit.org-config/public_html/dashboard/Scripts/BuildbotTesterQueueView.js:
+        (BuildbotTesterQueueView.prototype.update.appendBuilderQueueStatus):
+        (BuildbotTesterQueueView.prototype.update):
+        (BuildbotTesterQueueView.prototype.update.appendBuild): Deleted.
+
 2015-02-04  Simon Fraser  <simon.fraser@apple.com>
 
         WKTR should not use -mainScreen to pick a color profile