Changeset 90121 in webkit
- Timestamp:
- Jun 30, 2011, 8:30:32 AM (14 years ago)
- Location:
- trunk/Tools
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Tools/BuildSlaveSupport/build.webkit.org-config/public_html/TestFailures/LayoutTestResultsLoader.js
r90120 r90121 31 31 start: function(buildName, callback, errorCallback) { 32 32 var cacheKey = 'LayoutTestResultsLoader.' + this._builder.name + '.' + buildName; 33 const currentCachedDataVersion = 1;33 const currentCachedDataVersion = 2; 34 34 if (PersistentCache.contains(cacheKey)) { 35 35 var cachedData = PersistentCache.get(cacheKey); … … 57 57 result.tooManyFailures = root.getElementsByClassName('stopped-running-early-message').length > 0; 58 58 59 function testsForResultTable(regex) {59 function parseResultTable(regex) { 60 60 var paragraph = Array.prototype.findFirst.call(root.querySelectorAll('p'), function(paragraph) { 61 61 return regex.test(paragraph.innerText); … … 65 65 var table = paragraph.nextElementSibling; 66 66 console.assert(table.nodeName === 'TABLE'); 67 return Array.prototype.map.call(table.querySelectorAll('td:first-child > a'), function(elem) { 68 return elem.innerText; 67 return Array.prototype.map.call(table.rows, function(row) { 68 var links = row.getElementsByTagName('a'); 69 var result = { 70 name: links[0].innerText, 71 }; 72 for (var i = 1; i < links.length; ++i) { 73 var match = /^crash log \((.*)\)$/.exec(links[i].innerText); 74 if (!match) 75 continue; 76 result.crashingSymbol = match[1]; 77 break; 78 } 79 return result; 69 80 }); 70 81 } 71 82 72 testsForResultTable(/did not match expected results/).forEach(function(name) {73 result.tests[ name] = { failureType: 'fail' };83 parseResultTable(/did not match expected results/).forEach(function(testData) { 84 result.tests[testData.name] = { failureType: 'fail' }; 74 85 }); 75 testsForResultTable(/timed out/).forEach(function(name) {76 result.tests[ name] = { failureType: 'timeout' };86 parseResultTable(/timed out/).forEach(function(testData) { 87 result.tests[testData.name] = { failureType: 'timeout' }; 77 88 }); 78 testsForResultTable(/tool to crash/).forEach(function(name) { 79 result.tests[name] = { failureType: 'crash' }; 89 parseResultTable(/tool to crash/).forEach(function(testData) { 90 result.tests[testData.name] = { 91 failureType: 'crash', 92 crashingSymbol: testData.crashingSymbol, 93 }; 80 94 }); 81 testsForResultTable(/Web process to crash/).forEach(function(name) { 82 result.tests[name] = { failureType: 'webprocess crash' }; 95 parseResultTable(/Web process to crash/).forEach(function(testData) { 96 result.tests[testData.name] = { 97 failureType: 'webprocess crash', 98 crashingSymbol: testData.crashingSymbol, 99 }; 83 100 }); 84 101 -
trunk/Tools/BuildSlaveSupport/build.webkit.org-config/public_html/TestFailures/TestFailures.css
r90115 r90121 4 4 right: 5px; 5 5 color: #888; 6 font-size: 0.9em; 7 } 8 9 code { 6 10 font-size: 0.9em; 7 11 } -
trunk/Tools/BuildSlaveSupport/build.webkit.org-config/public_html/TestFailures/ViewController.js
r90120 r90121 261 261 return document.createTextNode(testResult.failureType); 262 262 263 var textNode = document.createTextNode(diagnosticInfo.text); 263 var textAndCrashingSymbol = document.createDocumentFragment(); 264 textAndCrashingSymbol.appendChild(document.createTextNode(diagnosticInfo.text)); 265 if (testResult.crashingSymbol) { 266 var code = document.createElement('code'); 267 code.appendChild(document.createTextNode(testResult.crashingSymbol)); 268 textAndCrashingSymbol.appendChild(document.createTextNode(' (')); 269 textAndCrashingSymbol.appendChild(code); 270 textAndCrashingSymbol.appendChild(document.createTextNode(')')); 271 } 272 264 273 if (!('url' in diagnosticInfo)) 265 return text Node;274 return textAndCrashingSymbol; 266 275 267 276 var link = document.createElement('a'); 268 277 link.href = diagnosticInfo.url; 269 link.appendChild(text Node);278 link.appendChild(textAndCrashingSymbol); 270 279 return link; 271 280 }, -
trunk/Tools/ChangeLog
r90120 r90121 1 2011-06-30 Adam Roben <aroben@apple.com> 2 3 Include the crashing symbol in crash logs links on TestFailures 4 5 Fixes <http://webkit.org/b/63465> Links to crash logs on TestFailures page should include 6 the crashing symbol (like links in results.html do) 7 8 Reviewed by David Kilzer. 9 10 * BuildSlaveSupport/build.webkit.org-config/public_html/TestFailures/LayoutTestResultsLoader.js: 11 (LayoutTestResultsLoader.prototype.start): Bumped the cache version because we now store 12 crashing symbols for crashing tests. Renamed testsForResultTable to parseResultTable because 13 it now returns more than just the test names. Specifically, it now looks for crash log links 14 and extracts the crashing symbol name from them. Updated callers of parseResultTable to 15 match its new behavior. Changed to store the crashing symbol along with the failure type in 16 the data we pass to the callback for tests which crashed. 17 18 * BuildSlaveSupport/build.webkit.org-config/public_html/TestFailures/TestFailures.css: 19 (code): Make <code> elements a little smaller because their contents can be quite long. 20 21 * BuildSlaveSupport/build.webkit.org-config/public_html/TestFailures/ViewController.js: 22 (ViewController.prototype._domForFailureDiagnosis): Include the crashing symbol inside a 23 <code> element in the link, if there is a crashing symbol. 24 1 25 2011-06-30 Adam Roben <aroben@apple.com> 2 26
Note:
See TracChangeset
for help on using the changeset viewer.