⚠ Archived content — this site is no longer maintained.   Current WebKit documentation is at docs.webkit.org.

Changeset 106727 in webkit


Ignore:
Timestamp:
Feb 3, 2012, 7:59:10 PM (15 years ago)
Author:
abarth@webkit.org
Message:

List of all failures in garden-o-matic should actually list all the failures
https://bugs.webkit.org/show_bug.cgi?id=77796

Reviewed by Eric Seidel.

This patch wires a bit more data into the new "All Failures" tab. I've
also iterated on how we enable this experimental feature. The tab is
still just a dumb list, but we'll make it smarter.

  • BuildSlaveSupport/build.webkit.org-config/public_html/TestFailures/scripts/controllers.js:
  • BuildSlaveSupport/build.webkit.org-config/public_html/TestFailures/scripts/garden-o-matic.js:
  • BuildSlaveSupport/build.webkit.org-config/public_html/TestFailures/scripts/ui.js:
  • BuildSlaveSupport/build.webkit.org-config/public_html/TestFailures/scripts/ui/failures.js:
Location:
trunk/Tools
Files:
5 edited

Legend:

Unmodified
Added
Removed
  • trunk/Tools/BuildSlaveSupport/build.webkit.org-config/public_html/TestFailures/scripts/controllers.js

    r101072 r106727  
    9595});
    9696
     97controllers.ExpectedFailures = base.extends(Object, {
     98    init: function(model, view, delegate)
     99    {
     100        this._model = model;
     101        this._view = view;
     102        this._delegate = delegate;
     103    },
     104    update: function()
     105    {
     106        var expectedOrUnexpectedFailures = results.expectedOrUnexpectedFailuresByTest(this._model.resultsByBuilder);
     107        this._view.setFailingTests(Object.keys(expectedOrUnexpectedFailures));
     108    }
     109});
     110
    97111var FailureStreamController = base.extends(Object, {
    98112    _resultsFilter: null,
  • trunk/Tools/BuildSlaveSupport/build.webkit.org-config/public_html/TestFailures/scripts/garden-o-matic.js

    r106713 r106727  
    3333
    3434var g_unexpectedFailuresController = null;
     35var g_failuresController = null;
    3536
    3637var g_losingTestCoverageBuilders = null;
     
    5051
    5152    base.callInParallel([model.updateRecentCommits, model.updateResultsByBuilder], function() {
     53        if (g_failuresController)
     54            g_failuresController.update();
    5255
    5356        updating.update('Analyzing test failures ...');
     
    8487        {
    8588            var resultsContainer = onebar.results();
     89            console.log(resultsContainer);
    8690            $(resultsContainer).empty().append(resultsView);
    8791            onebar.select('results');
     
    105109    unexpected.appendChild(unexpectedFailuresView);
    106110
    107     var expected = onebar.expected();
    108     if (expected) {
    109         var expectedFailuresView = new ui.failures.List();
    110         expected.appendChild(expectedFailuresView);
     111    var failures = onebar.failures();
     112    if (failures) {
     113        var failuresView = new ui.failures.List();
     114        g_failuresController = new controllers.ExpectedFailures(model.state, failuresView, onebarController);
     115        failures.appendChild(failuresView);
    111116    }
    112117
  • trunk/Tools/BuildSlaveSupport/build.webkit.org-config/public_html/TestFailures/scripts/ui.js

    r106713 r106727  
    6565            '<ul>' +
    6666                '<li><a href="#unexpected">Unexpected Failures</a></li>' +
    67                 '<li><a href="#expected">Expected Failures</a></li>' +
    6867                '<li><a href="#results">Results</a></li>' +
    6968            '</ul>' +
    7069            '<div id="unexpected"></div>' +
    71             '<div id="expected"></div>' +
     70            '<div id="failures"></div>' +
    7271            '<div id="results"></div>';
    7372        this._tabNames = [
    7473            'unexpected',
    75             'expected',
    7674            'results',
    7775        ]
    7876        this._tabs = $(this).tabs({
    79             disabled: [2],
     77            disabled: [1],
    8078        });
    81         if (!config.kExperimentalFeatures)
    82             this._tabs.tabs('remove', 1);
     79        if (config.kExperimentalFeatures) {
     80            this._tabs.tabs('add', '#failures', 'All Failures (experimental)');
     81            this._tabNames.push('failures');
     82        }
    8383    },
    8484    attach: function()
     
    8888    tabNamed: function(tabName)
    8989    {
     90        if (this._tabNames.indexOf(tabName) == -1)
     91            return null;
    9092        tab = document.getElementById(tabName);
    91         if (!tab)
    92             return null;
    9393        // We perform this sanity check below to make sure getElementById
    9494        // hasn't given us a node in some other unrelated part of the document.
     
    103103        return this.tabNamed('unexpected');
    104104    },
    105     expected: function()
     105    failures: function()
    106106    {
    107         return this.tabNamed('expected');
     107        return this.tabNamed('failures');
    108108    },
    109109    results: function()
  • trunk/Tools/BuildSlaveSupport/build.webkit.org-config/public_html/TestFailures/scripts/ui/failures.js

    r106713 r106727  
    131131    init: function()
    132132    {
    133         this.textContent = "TODO: List failures here.";
     133        this.textContent = 'Loading...';
     134    },
     135    setFailingTests: function(failingTestsList)
     136    {
     137        $(this).empty();
     138        var list = this.appendChild(document.createElement('ul'));
     139        failingTestsList.sort().forEach(function(failingTest) {
     140            list.appendChild(document.createElement('li')).textContent = failingTest;
     141        });
    134142    }
    135143});
  • trunk/Tools/ChangeLog

    r106726 r106727  
     12012-02-03  Adam Barth  <abarth@webkit.org>
     2
     3        List of all failures in garden-o-matic should actually list all the failures
     4        https://bugs.webkit.org/show_bug.cgi?id=77796
     5
     6        Reviewed by Eric Seidel.
     7
     8        This patch wires a bit more data into the new "All Failures" tab.  I've
     9        also iterated on how we enable this experimental feature.  The tab is
     10        still just a dumb list, but we'll make it smarter.
     11
     12        * BuildSlaveSupport/build.webkit.org-config/public_html/TestFailures/scripts/controllers.js:
     13        * BuildSlaveSupport/build.webkit.org-config/public_html/TestFailures/scripts/garden-o-matic.js:
     14        * BuildSlaveSupport/build.webkit.org-config/public_html/TestFailures/scripts/ui.js:
     15        * BuildSlaveSupport/build.webkit.org-config/public_html/TestFailures/scripts/ui/failures.js:
     16
    1172012-02-03  Ryosuke Niwa  <rniwa@webkit.org>
    218
Note: See TracChangeset for help on using the changeset viewer.