Changeset 125123 in webkit
- Timestamp:
- Aug 8, 2012 5:19:23 PM (12 years ago)
- Location:
- trunk/Tools
- Files:
-
- 2 added
- 11 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Tools/ChangeLog
r125115 r125123 1 2012-08-08 Ryosuke Niwa <rniwa@webkit.org> 2 3 Add Perf EWS IRC bot 4 https://bugs.webkit.org/show_bug.cgi?id=92913 5 6 Reviewed by Dirk Pranke. 7 8 Adds the preliminary implementation of perfalizer, a IRC bot that runs performance tests 9 based on IRC requests. 10 11 * Scripts/webkitpy/common/checkout/scm/scm_mock.py: 12 (MockSCM.head_svn_revision): The actual implementation returns string, so match that. 13 (MockSCM.svn_revision): Ditto. 14 * Scripts/webkitpy/common/net/bugzilla/bugzilla.py: 15 (Bugzilla.add_attachment_to_bug): Added mimetype. 16 * Scripts/webkitpy/common/net/bugzilla/bugzilla_mock.py: 17 (MockBugzilla.add_attachment_to_bug): Ditto. 18 * Scripts/webkitpy/common/system/filesystem.py: 19 (FileSystem.copytree): Added. 20 * Scripts/webkitpy/common/system/filesystem_mock.py: 21 (MockFileSystem.copytree): Added. 22 * Scripts/webkitpy/performance_tests/perftestsrunner_unittest.py: Rebaselined tests 23 that had assumed revision numbers were integers. 24 (test_run_with_json_output): 25 (test_run_with_description): 26 (test_run_generates_json_by_default): 27 (test_run_generates_and_show_results_page): 28 (test_run_with_json_source): 29 (test_run_with_multiple_repositories): 30 * Scripts/webkitpy/tool/bot/flakytestreporter_unittest.py: 31 * Scripts/webkitpy/tool/commands/__init__.py: 32 * Scripts/webkitpy/tool/commands/perfalizer.py: Added. 33 (PerfalizerTask): 34 (PerfalizerTask.__init__): 35 (PerfalizerTask._copy_build_product_without_patch): 36 (PerfalizerTask.run): 37 (PerfalizerTask.parent_command): 38 (PerfalizerTask.run_webkit_patch): 39 (PerfalizerTask._json_path): 40 (PerfalizerTask._results_page_path): 41 (PerfalizerTask._run_perf_test): 42 (PerfalizerTask.run_command): 43 (PerfalizerTask.command_passed): 44 (PerfalizerTask.command_failed): 45 (PerfalizerTask.refetch_patch): 46 (PerfalizerTask.expected_failures): 47 (PerfalizerTask.build_style): 48 (PerfTest): IRC command. 49 (PerfTest.execute): 50 (Perfalizer): IRC bot. 51 (Perfalizer.begin_work_queue): 52 (Perfalizer.work_item_log_path): 53 (Perfalizer._is_old_failure): 54 (Perfalizer.next_work_item): 55 (Perfalizer.process_work_item): 56 (Perfalizer.handle_unexpected_error): 57 (Perfalizer.handle_script_error): 58 * Scripts/webkitpy/tool/commands/perfalizer_unittest.py: Added. 59 (PerfalizerTaskTest): 60 (PerfalizerTaskTest._create_and_run_perfalizer): 61 (PerfalizerTaskTest._create_and_run_perfalizer.logger): 62 (PerfalizerTaskTest._create_and_run_perfalizer.run_webkit_patch): 63 (PerfalizerTaskTest._create_and_run_perfalizer.run_perf_test): 64 (PerfalizerTaskTest.test_run): 65 (PerfalizerTaskTest.test_run_with_clean_fails): 66 (PerfalizerTaskTest.test_run_with_update_fails): 67 (PerfalizerTaskTest.test_run_with_build_fails): 68 (PerfalizerTaskTest.test_run_with_perf_test_fails): 69 (PerfalizerTaskTest.test_run_without_results_page): 70 * Scripts/webkitpy/tool/commands/queues_unittest.py: 71 (AbstractPatchQueueTest.test_upload_results_archive_for_patch): Rebaselined. 72 * Scripts/webkitpy/tool/commands/upload_unittest.py: 73 (test_attach_to_bug): Ditto. 74 (test_attach_to_bug_no_description_or_comment): Ditto. 75 1 76 2012-08-08 Dirk Pranke <dpranke@chromium.org> 2 77 -
trunk/Tools/Scripts/webkitpy/common/checkout/scm/scm_mock.py
r118557 r125123 70 70 71 71 def head_svn_revision(self): 72 return 123472 return '1234' 73 73 74 74 def svn_revision(self, path): 75 return 567875 return '5678' 76 76 77 77 def create_patch(self, git_commit, changed_files=None): -
trunk/Tools/Scripts/webkitpy/common/net/bugzilla/bugzilla.py
r121269 r125123 579 579 return "bug-%s-%s.%s" % (bug_id, timestamp(), extension) 580 580 581 def add_attachment_to_bug(self, 582 bug_id, 583 file_or_string, 584 description, 585 filename=None, 586 comment_text=None): 581 def add_attachment_to_bug(self, bug_id, file_or_string, description, filename=None, comment_text=None, mimetype=None): 587 582 self.authenticate() 588 583 log('Adding attachment "%s" to %s' % (description, self.bug_url_for_bug_id(bug_id))) … … 591 586 file_object = self._file_object_for_upload(file_or_string) 592 587 filename = filename or self._filename_for_upload(file_object, bug_id) 593 self._fill_attachment_form(description, file_object, filename=filename )588 self._fill_attachment_form(description, file_object, filename=filename, mimetype=mimetype) 594 589 if comment_text: 595 590 log(comment_text) -
trunk/Tools/Scripts/webkitpy/common/net/bugzilla/bugzilla_mock.py
r121269 r125123 394 394 bug_id, cc, comment_text)) 395 395 396 def add_attachment_to_bug(self, 397 bug_id, 398 file_or_string, 399 description, 400 filename=None, 401 comment_text=None): 402 log("MOCK add_attachment_to_bug: bug_id=%s, description=%s filename=%s" % (bug_id, description, filename)) 396 def add_attachment_to_bug(self, bug_id, file_or_string, description, filename=None, comment_text=None, mimetype=None): 397 log("MOCK add_attachment_to_bug: bug_id=%s, description=%s filename=%s mimetype=%s" % 398 (bug_id, description, filename, mimetype)) 403 399 if comment_text: 404 400 log("-- Begin comment --") -
trunk/Tools/Scripts/webkitpy/common/system/filesystem.py
r112168 r125123 263 263 shutil.rmtree(path, ignore_errors=True) 264 264 265 def copytree(self, source, destination): 266 shutil.copytree(source, destination) 267 265 268 def split(self, path): 266 269 """Return (dirname, basename + '.' + ext)""" -
trunk/Tools/Scripts/webkitpy/common/system/filesystem_mock.py
r118979 r125123 379 379 self.dirs = set(filter(lambda d: not d.startswith(path), self.dirs)) 380 380 381 def copytree(self, source, destination): 382 source = self.normpath(source) 383 destination = self.normpath(destination) 384 385 for source_file in self.files: 386 if source_file.startswith(source): 387 destination_path = self.join(destination, self.relpath(source_file, source)) 388 self.maybe_make_directory(self.dirname(destination_path)) 389 self.files[destination_path] = self.files[source_file] 390 381 391 def split(self, path): 382 392 idx = path.rfind(self.sep) -
trunk/Tools/Scripts/webkitpy/performance_tests/perftestsrunner_unittest.py
r124949 r125123 269 269 {"Bindings/event-target-wrapper": {"max": 1510, "avg": 1489.05, "median": 1487, "min": 1471, "stdev": 14.46, "unit": "ms"}, 270 270 "inspector/pass.html:group_name:test_name": 42}, 271 "webkit-revision": 5678, "branch": "webkit-trunk"})271 "webkit-revision": "5678", "branch": "webkit-trunk"}) 272 272 273 273 def test_run_with_description(self): … … 279 279 {"Bindings/event-target-wrapper": {"max": 1510, "avg": 1489.05, "median": 1487, "min": 1471, "stdev": 14.46, "unit": "ms"}, 280 280 "inspector/pass.html:group_name:test_name": 42}, 281 "webkit-revision": 5678, "branch": "webkit-trunk"})281 "webkit-revision": "5678", "branch": "webkit-trunk"}) 282 282 283 283 def create_runner_and_setup_results_template(self, args=[]): … … 311 311 {"Bindings/event-target-wrapper": {"max": 1510, "avg": 1489.05, "median": 1487, "min": 1471, "stdev": 14.46, "unit": "ms"}, 312 312 "inspector/pass.html:group_name:test_name": 42}, 313 "webkit-revision": 5678, "branch": "webkit-trunk"}])313 "webkit-revision": "5678", "branch": "webkit-trunk"}]) 314 314 315 315 self.assertTrue(filesystem.isfile(output_json_path)) … … 325 325 expected_entry = {"timestamp": 123456789, "results": {"Bindings/event-target-wrapper": 326 326 {"max": 1510, "avg": 1489.05, "median": 1487, "min": 1471, "stdev": 14.46, "unit": "ms"}, 327 "inspector/pass.html:group_name:test_name": 42}, "webkit-revision": 5678, "branch": "webkit-trunk"}327 "inspector/pass.html:group_name:test_name": 42}, "webkit-revision": "5678", "branch": "webkit-trunk"} 328 328 329 329 self.maxDiff = None … … 374 374 {"Bindings/event-target-wrapper": {"max": 1510, "avg": 1489.05, "median": 1487, "min": 1471, "stdev": 14.46, "unit": "ms"}, 375 375 "inspector/pass.html:group_name:test_name": 42}, 376 "webkit-revision": 5678, "branch": "webkit-trunk",376 "webkit-revision": "5678", "branch": "webkit-trunk", 377 377 "key": "value"}) 378 378 … … 395 395 {"Bindings/event-target-wrapper": {"max": 1510, "avg": 1489.05, "median": 1487, "min": 1471, "stdev": 14.46, "unit": "ms"}, 396 396 "inspector/pass.html:group_name:test_name": 42.0}, 397 "webkit-revision": 5678, "some-revision": 5678, "branch": "webkit-trunk"})397 "webkit-revision": "5678", "some-revision": "5678", "branch": "webkit-trunk"}) 398 398 399 399 def test_run_with_upload_json(self): -
trunk/Tools/Scripts/webkitpy/tool/bot/flakytestreporter_unittest.py
r116572 r125123 126 126 cc: abarth@webkit.org 127 127 blocked: 50856 128 MOCK add_attachment_to_bug: bug_id=60001, description=Failure diff from mock-bot-id filename=failure.diff 128 MOCK add_attachment_to_bug: bug_id=60001, description=Failure diff from mock-bot-id filename=failure.diff mimetype=None 129 129 MOCK bug comment: bug_id=50000, cc=None 130 130 --- Begin comment --- -
trunk/Tools/Scripts/webkitpy/tool/commands/__init__.py
r116414 r125123 13 13 from webkitpy.tool.commands.gardenomatic import GardenOMatic 14 14 from webkitpy.tool.commands.openbugs import OpenBugs 15 from webkitpy.tool.commands.perfalizer import Perfalizer 15 16 from webkitpy.tool.commands.prettydiff import PrettyDiff 16 17 from webkitpy.tool.commands.queries import * -
trunk/Tools/Scripts/webkitpy/tool/commands/queues_unittest.py
r124354 r125123 174 174 queue._options.port = None 175 175 patch = queue._tool.bugs.fetch_attachment(10001) 176 expected_stderr = """MOCK add_attachment_to_bug: bug_id=50000, description=Archive of layout-test-results from bot filename=layout-test-results.zip 176 expected_stderr = """MOCK add_attachment_to_bug: bug_id=50000, description=Archive of layout-test-results from bot filename=layout-test-results.zip mimetype=None 177 177 -- Begin comment -- 178 178 The attached test failures were seen while running run-webkit-tests on the mock-queue. … … 406 406 --- End comment --- 407 407 408 MOCK add_attachment_to_bug: bug_id=50002, description=Failure diff from bot filename=failure.diff 408 MOCK add_attachment_to_bug: bug_id=50002, description=Failure diff from bot filename=failure.diff mimetype=None 409 409 MOCK bug comment: bug_id=50002, cc=None 410 410 --- Begin comment --- … … 413 413 --- End comment --- 414 414 415 MOCK add_attachment_to_bug: bug_id=50002, description=Archive of layout-test-results from bot filename=layout-test-results.zip 415 MOCK add_attachment_to_bug: bug_id=50002, description=Archive of layout-test-results from bot filename=layout-test-results.zip mimetype=None 416 416 MOCK bug comment: bug_id=50000, cc=None 417 417 --- Begin comment --- -
trunk/Tools/Scripts/webkitpy/tool/commands/upload_unittest.py
r101834 r125123 80 80 options.comment = "extra comment" 81 81 options.description = "file description" 82 expected_stderr = """MOCK add_attachment_to_bug: bug_id=50000, description=file description filename=None 82 expected_stderr = """MOCK add_attachment_to_bug: bug_id=50000, description=file description filename=None mimetype=None 83 83 -- Begin comment -- 84 84 extra comment … … 91 91 options.comment = None 92 92 options.description = None 93 expected_stderr = """MOCK add_attachment_to_bug: bug_id=50000, description=file.txt filename=None 93 expected_stderr = """MOCK add_attachment_to_bug: bug_id=50000, description=file.txt filename=None mimetype=None 94 94 """ 95 95 self.assert_execute_outputs(AttachToBug(), [50000, "path/to/file.txt"], options=options, expected_stderr=expected_stderr)
Note: See TracChangeset
for help on using the changeset viewer.