| OLD | NEW |
| 1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 /** | 5 /** |
| 6 * @fileoverview Base JS file for pages that want to parse the results JSON | 6 * @fileoverview Base JS file for pages that want to parse the results JSON |
| 7 * from the testing bots. This deals with generic utility functions, visible | 7 * from the testing bots. This deals with generic utility functions, visible |
| 8 * history, popups and appending the script elements for the JSON files. | 8 * history, popups and appending the script elements for the JSON files. |
| 9 * | 9 * |
| 10 * The calling page is expected to implement the following "abstract" | 10 * The calling page is expected to implement the following "abstract" |
| (...skipping 78 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 89 var FIXABLE_COUNT_KEY = 'fixableCount'; | 89 var FIXABLE_COUNT_KEY = 'fixableCount'; |
| 90 var ALL_FIXABLE_COUNT_KEY = 'allFixableCount'; | 90 var ALL_FIXABLE_COUNT_KEY = 'allFixableCount'; |
| 91 var CHROME_REVISIONS_KEY = 'chromeRevision'; | 91 var CHROME_REVISIONS_KEY = 'chromeRevision'; |
| 92 var WEBKIT_REVISIONS_KEY = 'webkitRevision'; | 92 var WEBKIT_REVISIONS_KEY = 'webkitRevision'; |
| 93 var TIMESTAMPS_KEY = 'secondsSinceEpoch'; | 93 var TIMESTAMPS_KEY = 'secondsSinceEpoch'; |
| 94 var BUILD_NUMBERS_KEY = 'buildNumbers'; | 94 var BUILD_NUMBERS_KEY = 'buildNumbers'; |
| 95 var TESTS_KEY = 'tests'; | 95 var TESTS_KEY = 'tests'; |
| 96 | 96 |
| 97 // These should match the testtype uploaded to test-results.appspot.com. | 97 // These should match the testtype uploaded to test-results.appspot.com. |
| 98 // See http://test-results.appspot.com/testfile. | 98 // See http://test-results.appspot.com/testfile. |
| 99 var TEST_TYPES = ['app_unittests', 'base_unittests', | 99 var TEST_TYPES = ['app_unittests', 'base_unittests', 'browser_tests', |
| 100 'browser_tests', 'courgette_unittests', 'googleurl_unittests', | 100 'courgette_unittests', 'crypto_unittests', 'googleurl_unittests', |
| 101 'gpu_unittests', 'installer_util_unittests', 'interactive_ui_tests', | 101 'gpu_unittests', 'installer_util_unittests', 'interactive_ui_tests', |
| 102 'ipc_tests', 'layout-tests', 'media_unittests', | 102 'ipc_tests', 'layout-tests', 'media_unittests', |
| 103 'mini_installer_test', 'nacl_ui_tests', 'net_unittests', | 103 'mini_installer_test', 'nacl_ui_tests', 'net_unittests', |
| 104 'printing_unittests', 'sync_unit_tests', 'sync_integration_tests', | 104 'printing_unittests', 'sync_unit_tests', 'sync_integration_tests', |
| 105 'test_shell_tests', 'ui_tests', 'unit_tests']; | 105 'test_shell_tests', 'ui_tests', 'unit_tests']; |
| 106 | 106 |
| 107 var RELOAD_REQUIRING_PARAMETERS = ['showAllRuns', 'group', 'testType']; | 107 var RELOAD_REQUIRING_PARAMETERS = ['showAllRuns', 'group', 'testType']; |
| 108 | 108 |
| 109 // Enum for indexing into the run-length encoded results in the JSON files. | 109 // Enum for indexing into the run-length encoded results in the JSON files. |
| 110 // 0 is where the count is length is stored. 1 is the value. | 110 // 0 is where the count is length is stored. 1 is the value. |
| (...skipping 272 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 383 function getCurrentBuilderGroup(opt_state) { | 383 function getCurrentBuilderGroup(opt_state) { |
| 384 var state = opt_state || currentState; | 384 var state = opt_state || currentState; |
| 385 switch (state.testType) { | 385 switch (state.testType) { |
| 386 case 'layout-tests': | 386 case 'layout-tests': |
| 387 return LAYOUT_TESTS_BUILDER_GROUPS[state.group] | 387 return LAYOUT_TESTS_BUILDER_GROUPS[state.group] |
| 388 break; | 388 break; |
| 389 case 'app_unittests': | 389 case 'app_unittests': |
| 390 case 'base_unittests': | 390 case 'base_unittests': |
| 391 case 'browser_tests': | 391 case 'browser_tests': |
| 392 case 'courgette_unittests': | 392 case 'courgette_unittests': |
| 393 case 'crypto_unittests': |
| 393 case 'googleurl_unittests': | 394 case 'googleurl_unittests': |
| 394 case 'gpu_unittests': | 395 case 'gpu_unittests': |
| 395 case 'installer_util_unittests': | 396 case 'installer_util_unittests': |
| 396 case 'interactive_ui_tests': | 397 case 'interactive_ui_tests': |
| 397 case 'ipc_tests': | 398 case 'ipc_tests': |
| 398 case 'media_unittests': | 399 case 'media_unittests': |
| 399 case 'mini_installer_test': | 400 case 'mini_installer_test': |
| 400 case 'nacl_ui_tests': | 401 case 'nacl_ui_tests': |
| 401 case 'net_unittests': | 402 case 'net_unittests': |
| 402 case 'printing_unittests': | 403 case 'printing_unittests': |
| (...skipping 618 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1021 !(popup.compareDocumentPosition(e.target) & 16)) { | 1022 !(popup.compareDocumentPosition(e.target) & 16)) { |
| 1022 hidePopup(); | 1023 hidePopup(); |
| 1023 } | 1024 } |
| 1024 }, false); | 1025 }, false); |
| 1025 | 1026 |
| 1026 window.addEventListener('load', function() { | 1027 window.addEventListener('load', function() { |
| 1027 // This doesn't seem totally accurate as there is a race between | 1028 // This doesn't seem totally accurate as there is a race between |
| 1028 // onload firing and the last script tag being executed. | 1029 // onload firing and the last script tag being executed. |
| 1029 logTime('Time to load JS', pageLoadStartTime); | 1030 logTime('Time to load JS', pageLoadStartTime); |
| 1030 }, false); | 1031 }, false); |
| OLD | NEW |