Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(76)

Side by Side Diff: third_party/WebKit/Tools/Scripts/webkitpy/w3c/deps_updater.py

Issue 2655783005: Remove extra newlines added to auto-importer CL descriptions. (Closed)
Patch Set: Created 3 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « no previous file | third_party/WebKit/Tools/Scripts/webkitpy/w3c/deps_updater_unittest.py » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 # Copyright 2014 The Chromium Authors. All rights reserved. 1 # Copyright 2014 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 """Fetches a copy of the latest state of a W3C test repository and commits. 5 """Fetches a copy of the latest state of a W3C test repository and commits.
6 6
7 If this script is given the argument --auto-update, it will also: 7 If this script is given the argument --auto-update, it will also:
8 1. Upload a CL. 8 1. Upload a CL.
9 2. Trigger try jobs and wait for them to complete. 9 2. Trigger try jobs and wait for them to complete.
10 3. Make any changes that are required for new failing tests. 10 3. Make any changes that are required for new failing tests.
(...skipping 324 matching lines...) Expand 10 before | Expand all | Expand 10 after
335 ] + ['--cc=' + email for email in cc_list]) 335 ] + ['--cc=' + email for email in cc_list])
336 336
337 def _cl_description(self): 337 def _cl_description(self):
338 description = self.check_run(['git', 'log', '-1', '--format=%B']) 338 description = self.check_run(['git', 'log', '-1', '--format=%B'])
339 build_link = self._build_link() 339 build_link = self._build_link()
340 if build_link: 340 if build_link:
341 description += 'Build: %s\n\n' % build_link 341 description += 'Build: %s\n\n' % build_link
342 description += 'TBR=qyearsley@chromium.org\n' 342 description += 'TBR=qyearsley@chromium.org\n'
343 # Move any NOEXPORT tag to the end of the description. 343 # Move any NOEXPORT tag to the end of the description.
344 description = description.replace('NOEXPORT=true', '') 344 description = description.replace('NOEXPORT=true', '')
345 description = description.replace('\n\n\n\n', '\n\n')
345 description += 'NOEXPORT=true' 346 description += 'NOEXPORT=true'
346 return description 347 return description
347 348
348 def _build_link(self): 349 def _build_link(self):
349 """Returns a link to a job, if running on buildbot.""" 350 """Returns a link to a job, if running on buildbot."""
350 master_name = self.host.environ.get('BUILDBOT_MASTERNAME') 351 master_name = self.host.environ.get('BUILDBOT_MASTERNAME')
351 builder_name = self.host.environ.get('BUILDBOT_BUILDERNAME') 352 builder_name = self.host.environ.get('BUILDBOT_BUILDERNAME')
352 build_number = self.host.environ.get('BUILDBOT_BUILDNUMBER') 353 build_number = self.host.environ.get('BUILDBOT_BUILDNUMBER')
353 if not (master_name and builder_name and build_number): 354 if not (master_name and builder_name and build_number):
354 return None 355 return None
(...skipping 95 matching lines...) Expand 10 before | Expand all | Expand 10 after
450 """Returns a dict mapping source to dest name for layout tests that have been renamed.""" 451 """Returns a dict mapping source to dest name for layout tests that have been renamed."""
451 out = self.check_run(['git', 'diff', 'origin/master', '-M100%', '--diff- filter=R', '--name-status']) 452 out = self.check_run(['git', 'diff', 'origin/master', '-M100%', '--diff- filter=R', '--name-status'])
452 renamed_tests = {} 453 renamed_tests = {}
453 for line in out.splitlines(): 454 for line in out.splitlines():
454 _, source_path, dest_path = line.split() 455 _, source_path, dest_path = line.split()
455 source_test = self.finder.layout_test_name(source_path) 456 source_test = self.finder.layout_test_name(source_path)
456 dest_test = self.finder.layout_test_name(dest_path) 457 dest_test = self.finder.layout_test_name(dest_path)
457 if source_test and dest_test: 458 if source_test and dest_test:
458 renamed_tests[source_test] = dest_test 459 renamed_tests[source_test] = dest_test
459 return renamed_tests 460 return renamed_tests
OLDNEW
« no previous file with comments | « no previous file | third_party/WebKit/Tools/Scripts/webkitpy/w3c/deps_updater_unittest.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698