Don't prompt for confirmation in `git cl upload --dependencies`

This is a pretty intentional command, I don't see why the confirmation
would be required.

Bug: None
Change-Id: I111bb39e3b5f467901be5c986847ace3c6efa7ee
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/4261467
Commit-Queue: Josip Sokcevic <sokcevic@chromium.org>
Auto-Submit: Victor Vianna <victorvianna@google.com>
Reviewed-by: Josip Sokcevic <sokcevic@chromium.org>
changes/67/4261467/2
Victor Hugo Vianna Silva 2 years ago committed by LUCI CQ
parent d85c5bc6ff
commit dd03016926

@ -3871,10 +3871,6 @@ def upload_branch_deps(cl, args, force=False):
print('There are no dependent local branches for %s' % root_branch)
return 0
if not force:
confirm_or_exit('This command will checkout all dependent branches and run '
'"git cl upload".', action='continue')
# Record all dependents that failed to upload.
failures = {}
# Go through all dependents, checkout the branch and upload.

@ -1945,11 +1945,6 @@ class TestGitCl(unittest.TestCase):
ret = git_cl.upload_branch_deps(MockChangelist(), [])
# CMDupload should have been called 5 times because of 5 dependent branches.
self.assertEqual(5, len(git_cl.CMDupload.mock_calls))
self.assertIn(
'This command will checkout all dependent branches '
'and run "git cl upload". Press Enter to continue, '
'or Ctrl+C to abort',
sys.stdout.getvalue())
self.assertEqual(0, ret)
def test_gerrit_change_id(self):

Loading…
Cancel
Save