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

Unified Diff: tests/git_cl_test.py

Issue 1761743002: git cl upload for Gerit no-squash: correct detect missing Change-Id. (Closed) Base URL: https://chromium.googlesource.com/chromium/tools/depot_tools.git@G0800
Patch Set: fix tests Created 4 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « git_cl.py ('k') | tests/git_footers_test.py » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tests/git_cl_test.py
diff --git a/tests/git_cl_test.py b/tests/git_cl_test.py
index f5b3257c067220c5552e58e11ae6545db81a96b9..f1cee8a2793c340ec45ccd13eaa1ab4f78483096 100755
--- a/tests/git_cl_test.py
+++ b/tests/git_cl_test.py
@@ -660,6 +660,8 @@ class TestGitCl(TestCase):
self.calls += self._gerrit_upload_calls(
description, reviewers, squash,
expected_upstream_ref=expected_upstream_ref)
+ # Uncomment when debugging.
+ # print '\n'.join(map(lambda x: '%2i: %s' % x, enumerate(self.calls)))
git_cl.main(['upload'] + upload_args)
def test_gerrit_upload_without_change_id(self):
@@ -671,20 +673,20 @@ class TestGitCl(TestCase):
def test_gerrit_no_reviewer(self):
self._run_gerrit_upload_test(
[],
- 'desc\n\nBUG=\nChange-Id:123456789\n',
+ 'desc\n\nBUG=\n\nChange-Id: I123456789\n',
[])
def test_gerrit_reviewers_cmd_line(self):
self._run_gerrit_upload_test(
['-r', 'foo@example.com'],
- 'desc\n\nBUG=\nChange-Id:123456789',
+ 'desc\n\nBUG=\n\nChange-Id: I123456789',
['foo@example.com'])
def test_gerrit_reviewer_multiple(self):
self._run_gerrit_upload_test(
[],
- 'desc\nTBR=reviewer@example.com\nBUG=\nR=another@example.com\n'
- 'Change-Id:123456789\n',
+ 'desc\nTBR=reviewer@example.com\nBUG=\nR=another@example.com\n\n'
+ 'Change-Id: 123456789\n',
['reviewer@example.com', 'another@example.com'])
def test_gerrit_upload_squash(self):
« no previous file with comments | « git_cl.py ('k') | tests/git_footers_test.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698