This is an archive of the discontinued Mercurial Phabricator instance.

branch: add tests which shows branch can be closed from a non-branchhead cset
ClosedPublic

Authored by khanchi97 on Apr 19 2019, 3:48 AM.

Details

Summary

This patch shows that we can close a branch even from a cset which is not
a branch head. It was supposed to abort this operation.
Next patch will be fixing the issue.

Diff Detail

Repository
rHG Mercurial
Lint
Lint Skipped
Unit
Unit Tests Skipped

Event Timeline

khanchi97 created this revision.Apr 19 2019, 3:48 AM
khanchi97 added inline comments.Apr 25 2019, 1:47 PM
tests/test-branches.t
961

I created this patch assuming that hg should not allow to create a branch closing commit from a cset which is not a branch head. Let me know if I am missing something here.

pulkit accepted this revision.Apr 25 2019, 1:51 PM
pulkit added a subscriber: pulkit.

Queueing this, many thanks!

tests/test-branches.t
961

I think that the assumption is correct. hg help commit says --close-branch mark a branch head as closed.

So it should definitely be a head.

This revision was automatically updated to reflect the committed changes.