1 2013-10-25 Ryosuke Niwa <rniwa@webkit.org>
3 Links in new flakiness dashboard could benefit from tooltips
4 https://bugs.webkit.org/show_bug.cgi?id=123381
6 Reviewed by Alexey Proskuryakov.
8 Add title content attribute on each hyperlink in the builder pane.
11 (TestResultsView._populateBuilderPane):
13 2013-10-25 Ryosuke Niwa <rniwa@webkit.org>
15 Commit the right change.
19 2013-10-25 Ryosuke Niwa <rniwa@webkit.org>
21 The new flakiness dashboard should sort builder and test names
22 https://bugs.webkit.org/show_bug.cgi?id=123363
24 Reviewed by Simon Fraser.
26 Sort the forgotten builders in the menu.
30 2013-10-25 Ryosuke Niwa <rniwa@webkit.org>
32 The new flakiness dashboard should sort builder and test names
33 https://bugs.webkit.org/show_bug.cgi?id=123363
35 Reviewed by Simon Fraser.
37 Sort builders and tests by their name in each pane.
40 (TestResultsView._populateTestPane): Lexicologically sort builders by their name.
41 (TestResultsView._sortObjectsByName): Added.
42 (TestResultsView._populateBuilderPane): Lexicologically sort builders by their name.
44 2013-10-25 Ryosuke Niwa <rniwa@webkit.org>
46 Merge revision columns in flakiness dashboard
47 https://bugs.webkit.org/show_bug.cgi?id=123360
49 Reviewed by Simon Fraser.
51 Merge revision numbers into one cell separated by /, and clearly label them as "latest revisions".
52 Also add colors for missing & audio failures so that they won't be an empty cell.
55 (TestResultsView._createTestResultHeader): Create a single th for the list of repository names.
56 (TestResultsView._createTestResultRow): Use single td for all revision numbers.
58 (.this.formattedRevision): Don't prefix revision numbers with '@' when we're not in the tooltip.
60 (.resultsTable .AUDIO a): Added.
61 (.resultsTable .MISSING a): Added.
63 2013-10-25 Ryosuke Niwa <rniwa@webkit.org>
65 One more build fix. Put each latest revision information in an actual td.
69 2013-10-25 Ryosuke Niwa <rniwa@webkit.org>
71 Yet another set of build fixes.
73 1. Manually strip / from revisions JSON if there is any.
74 2. Suppress warnings from ob_end_flush.
75 3. Allow "+" in actual and expected results as used in "TEXT+IMAGE".
77 * public/api/report.php:
78 * public/include/test-results.php:
80 2013-10-25 Ryosuke Niwa <rniwa@webkit.org>
82 Another build fix. Move .htaccess to public.
85 * public/.htaccess: Copied from .htaccess.
87 2013-10-25 Ryosuke Niwa <rniwa@webkit.org>
89 It turns out that the current instruction only works on Mountain Lion.
91 Also fixed some typos.
95 2013-10-24 Ryosuke Niwa <rniwa@webkit.org>
97 Add an instruction on how to setup test-results app
98 https://bugs.webkit.org/show_bug.cgi?id=123321
100 Rubber-stamped by Stephanie Lewis.
102 Added Install.md and updated config.json accordingly.
104 Also moved init-database.sql out of public/include since it doesn't need to be accessible via httpd.
108 * init-database.sql: Moved from public/include/init-database.sql.
110 2013-10-24 Ryosuke Niwa <rniwa@webkit.org>
112 Move everything except ChangeLog and config.json into public directory.
113 https://bugs.webkit.org/show_bug.cgi?id=123319
115 Rubber-stamped by Stephanie Lewis.
118 * admin/admin.css: Removed.
119 * admin/builders.php: Removed.
120 * admin/index.php: Removed.
121 * admin/repositories.php: Removed.
123 * api/failing-tests.php: Removed.
124 * api/manifest.php: Removed.
125 * api/report.php: Removed.
126 * api/results.php: Removed.
127 * common.css: Removed.
128 * config.json: Copied from include/config.json.
130 * include/admin-footer.php: Removed.
131 * include/admin-header.php: Removed.
132 * include/config.json: Removed.
133 * include/db.php: Removed.
134 * include/init-database.sql: Removed.
135 * include/json-shared.php: Removed.
136 * include/test-results.php: Removed.
137 * index.html: Removed.
139 * js/autocompleter.js: Removed.
140 * js/build.js: Removed.
141 * js/dom.js: Removed.
144 * public/admin: Copied from admin.
145 * public/api: Copied from api.
146 * public/common.css: Copied from common.css.
147 * public/include: Copied from include.
148 * public/include/config.json: Removed.
149 * public/include/db.php:
150 * public/index.html: Copied from index.html.
151 * public/js: Copied from js.
152 * public/main.css: Copied from main.css.
154 2013-10-24 Ryosuke Niwa <rniwa@webkit.org>
156 Showing lists of flaky tests for a builder takes too long
157 https://bugs.webkit.org/show_bug.cgi?id=123311
159 Reviewed by Sam Weinig.
161 Generate JSONs for tests failing, flaky, or with wrong expectation at the time a builder reports results
162 instead when the frontend requests to those those results since it takes multiple seconds or minutes to
163 generate those JSON files.
165 * api/failing-tests.php: Moved and renamed to manually generate all JSON files for a given builder.
168 * api/report.php: Manually flush and end the request (to avoid blocking run-webkit-tests on the other side
169 for minutes), then generate JSONs for tests that are failing, are flaky, and have wrong expectations.
171 * api/results.php: Merge format_result_rows here since it's not used anywhere else.
173 * include/config.json: Added the path to the data directory into which JSON files are generated.
176 (configPath): Takes a relative path value from config.json, and resolves it.
178 * include/json-shared.php:
179 (echo_success): Extracted from exit_with_success.
182 * include/test-results.php:
183 (add_builder): Extracted from add_build.
185 (ResultsJSONWriter): Extracted from api/failing-tests.php.
186 (ResultsJSONWriter.__construct):
187 (ResultsJSONWriter.start):
188 (ResultsJSONWriter.end):
189 (ResultsJSONWriter.add_results_for_test_if_matches):
190 (ResultsJSONWriter.pass_for_failure_type):
191 (FailingResultsJSONWriter): Extracted from index.html's TestResultsView._matchesFailureType.
192 (FailingResultsJSONWriter.__construct):
193 (FailingResultsJSONWriter.pass_for_failure_type):
194 (FlakyResultsJSONWriter): Ditto.
195 (FlakyResultsJSONWriter.__construct):
196 (FlakyResultsJSONWriter.pass_for_failure_type):
197 (WrongExpectationsResultsJSONWriter): Ditto.
198 (WrongExpectationsResultsJSONWriter.__construct):
199 (WrongExpectationsResultsJSONWriter.pass_for_failure_type):
200 (ResultsJSONGenerator): Ditto.
201 (ResultsJSONGenerator.__construct):
202 (ResultsJSONGenerator.generate):
203 (ResultsJSONGenerator.open_json_for_failure_type):
204 (ResultsJSONGenerator.write_jsons):
208 (TestResultsView.setBuilders):
209 (TestResultsView._createResultCell): Add a hyperlink to results.html in the tooltip.
210 (TestResultsView.fetchFailingTestsForBuilder): Fetch the generated JSON files.
212 2013-10-23 Ryosuke Niwa <rniwa@webkit.org>
214 Reverted erroneously committed changes from the previous commit.
218 2013-10-23 Ryosuke Niwa <rniwa@webkit.org>
220 Clicking on a test name on the new flakiness dashboard should add a new test pane
221 https://bugs.webkit.org/show_bug.cgi?id=123194
223 Reviewed by Simon Fraser.
225 Added a new click handler on each test name inside the builder test view add a new test pane.
226 Moved the old trac link to a right-arrow inline SVG icon.
228 Also tweaked the style so that the builder test view looks different from other test panes.
231 (TestResultsView._urlFromTest): Extracted from TestResultsView._linkifiedTestName.
232 (TestResultsView._populateBuilderPane): Fetch the test when its name is clicked.
233 Added a circled right arrow for the old trac link.
234 * main.css: Tweaked the style to move the rounded border around the builder test view to be
235 around the form controls to clearly differentiate it from a regular test pane.
237 2013-10-22 Ryosuke Niwa <rniwa@webkit.org>
239 New flakiness dashboard's test pane should show the latest WebKit revision for each builder
240 https://bugs.webkit.org/show_bug.cgi?id=123189
242 Reviewed by Simon Fraser.
245 (TestResultsView._populateTestPane): Call _createTestResultHeader and _createTestResultRow with
246 a list of repository information.
247 (TestResultsView._createTestResultHeader): Optionally creates headers for a list of repositories.
248 (TestResultsView._createTestResultRow): Add a hyperlinked revision information for each builder.
249 Also add a hyperlink to file a Bugzilla bug when there is no bug associated with the test already.
251 (Build.formattedRevision): Extracted from Build.formattedRevisions.
252 (Build.formattedRevisions):
254 2013-10-22 Ryosuke Niwa <rniwa@webkit.org>
256 Make tables on the new flakiness dashboard sortable
257 https://bugs.webkit.org/show_bug.cgi?id=123141
259 Reviewed by Simon Fraser.
261 Use jquery.tablesorter.js to make test and builder tables sortable. The jquery plugin is already used by run-perf-tests.
264 (TestResultsView._populateTestPane): Add tablesorter to the class name and wrap tr's inside a tbody so that tablesorter
266 (TestResultsView._populateBuilderPane): Ditto.
268 (.resultsTable thead): Use cursor: pointer to signify the fact it's clickable.
269 (.resultsTable th): Don't repeat arrows.
270 (.resultsTable th.headerSortUp): Inline SVG up arrow.
271 (.resultsTable th.headerSortDown): Inline SVG down arrow.
273 2013-10-21 Ryosuke Niwa <rniwa@webkit.org>
275 New flakiness dashboard should hyperlink test names, WebKit revisions, and bubbles
276 https://bugs.webkit.org/show_bug.cgi?id=123134
278 Reviewed by Stephanie Lewis.
280 Copied admin.css, admin-header.php, admin-footer.php, builders.php, repositories.php from WebKit Perf Monitor.
281 (Unfortunately WebKit Perf Monitor hasn't been committed into WebKit repository just yet.)
283 Updated various parts of index.html to linkify test names, build numbers, and bubbles (to results page).
285 * admin/admin.css: Added.
286 * admin/builders.php: Added.
287 * admin/index.php: Removed the duplicated code now that it uses admin-header.php.
288 * admin/repositories.php: Added.
289 * api/manifest.php: Use camelCase for blame_url and build_url to be consistent with other JSON properties.
290 Also exported testCategories from config so that we can linkify test names in the dashboard.
291 * include/admin-footer.php: Added.
292 * include/admin-header.php: Added.
293 * include/config.json: Added test categories. This avoids hard-coding the URL to trac in php/js.
294 * include/init-database.sql: Added name and build_url to builders table and category to tests.
295 * include/test-results.php: Assume the test category to be LayoutTest for now.
298 (TestResultsView): Initialize _builders, _slaves, _repositories, _testCategories as dictionaries as intended.
299 (TestResultsView.setTestCategories): Added.
300 (TestResultsView._createResultCell): Dynamically resolve URLs of results page and and build page.
301 (TestResultsView._populateTestPane): Linkify the test name. Unfortunately we don't have a test object anywhere.
302 We need to figure out a way to find the test object here eventually. For now, hard-coding "LayoutTest" works.
303 (TestResultsView._linkifiedTestName): Added.
304 (TestResultsView._createBuildsAndComputeSlownessOfResults): Takes builderId to set "builder" property on each
305 result object as it's used by Build class.
306 (TestResultsView._populateBuilderPane):
310 (Build.buildUrl): Support $builderName so that we don't have to keep repeating builder names in the database.
311 (Build.revision): Don't access [0] if revisions[repositoryId] was undefined.
313 2013-10-21 Ryosuke Niwa <rniwa@webkit.org>
315 New flakiness dashboard should align results by revision numbers
316 https://bugs.webkit.org/show_bug.cgi?id=123129
318 Reviewed by Tim Horton.
320 * include/config.json: Specify the default cache time to be 10 minutes.
321 * include/json-shared.php: Added Expires and Cache-Control headers. It's configurable via config.json.
323 (TestResultsView._createResultCell): Don't put '-' in a result cell without time.
324 (TestResultsView._populateTestPane): Create an array of build times ordered from the newest to the oldest.
325 Not that build.time() is the newest commit time among all repository for each result. e.g. if we had
326 both WebKit and Safari repository information in a given result, the newer of the two will be used.
327 (TestResultsView._createTestResultHeader): Added.
328 (TestResultsView._createBuildsAndComputeSlownessOfResults): Extracted from _createTestResultRow so
329 that _populateTestPane could use Build object before calling _createTestResultRow.
330 (TestResultsView._createTestResultRow): Takes buildTimes. Insert an empty cell for a build time if
331 the current row doesn't contain that a result for that build time.
332 (TestResultsView._populateBuilderPane):
333 * main.css: Tweaked the style so that bubbles are aligned vertically without '-'.
335 (.resultsTable thead th):
336 (.resultsTable .resultCell):
338 (.resultsTable span a):
340 2013-10-21 Ryosuke Niwa <rniwa@webkit.org>
342 New flakiness dashboard show test time, modifiers, and flaky tests
343 https://bugs.webkit.org/show_bug.cgi?id=123119
345 Reviewed by Tim Horton.
347 * api/failing-tests.php: Manually serialize each row in the results to avoid hitting the memory limit.
349 (Database::query): Added.
350 (Database::fetch_next_row): Added.
351 * include/init-database.sql: Added modifiers and time columns to results table.
352 * include/test-results.php:
353 (store_test_results): Update start_time and end_time to the union of the new interval and the existing interval.
354 (recursively_add_test_results): Handle empty $full_name to eliminate the loop over tests in store_test_results.
355 Also verify that each test name, expected and actual results conform to the specific format to prevent XSS.
356 Also use insert_row instead of select_or_insert_row to avoid issuing an unnecessary SQL query.
357 (format_result): Extracted from format_result_rows. Used in failing-tests.php.
359 (TestResultsView): Added _currentBuilderFailureType and _currentBuilderDays.
360 (TestResultsView._createResultCell): Show the test time and the expected result.
361 (TestResultsView._createTestResultRow): Compute the slowest run and also round time to tenth of second for time
362 less than 10s or second if it's more than 10s so that the test time will always be shown in two digits.
363 Also show the bug number and the latest expected result on the left columns after linkifying the bug numbers.
364 (TestResultsView._matchesFailureType): Added. Determines whether results is of a particular failure type.
365 (TestResultsView._populateBuilderPane):
366 (TestResultsView.fetchFailingTestsForBuilder): Store the failure type such as flaky, wrongtestexpectations.
367 (TestResultsView.updateLocationHash):
368 (TestResultsView.loadTestsFromLocationHash):
371 (element): appendChild if an item is a Node. Otherwise, e.g. integer, create a text node out of toString() call.
372 * main.css: Updated styles.
374 2013-10-18 Ryosuke Niwa <rniwa@webkit.org>
376 New flakiness dashboard should support showing the failing tests per builder
377 https://bugs.webkit.org/show_bug.cgi?id=123011
379 Reviewed by Timothy Hatcher.
381 Added the feature. Also did some refactoring to add this feature.
384 * api/failing-tests.php: Added.
385 * api/manifest.php: Removed the code to make maps by id. The work is now done in index.html.
387 * common.css: Added. Extracted from index.html.
388 * include/test-results.php: Extracted parse_revisions_array and format_result_rows from results.php.
391 (TestResultsView.setAvailableTests): Added.
392 (TestResultsView.showTooltip): Fixed the code to compute x and y coordinates of the tooltip to take
393 scrolled positions into account.
394 (TestResultsView._createTestResultRow): Extracted from _populateTestPane.
395 (TestResultsView.fetchTest): Added the code to show "Loading..." in the pane while loading the JSON.
396 (TestResultsView.fetchTests): Respect the doNotUpdateHash flag.
397 (TestResultsView._populateBuilderPane): Added.
398 (TestResultsView.fetchFailingTestsForBuilder): Added.
399 (TestResultsView.updateLocationHash): Serialize builder & builderDays.
400 (TestResultsView.locationHashChanged): Don't delete existing test panes since that's now done in
401 loadTestsFromLocationHash.
402 (TestResultsView.loadTestsFromLocationHash): Take care of both 'tests' and 'builder' components.
403 (fetchManifest): Setup the UI to select a builder.