Mercurial > hg-stable
comparison tests/test-branches.t @ 19305:b500a663a2c7 stable
commit: amending with --close-branch (issue3445)
You can't close a branch that hasn't got a head.
newbranch + commit --close-branch must fail
newbranch + commit + commit --amend --close-branch must fail
You must not be allowed to close a branch that is not defined.
author | Iulian Stana <julian.stana@gmail.com> |
---|---|
date | Thu, 02 May 2013 19:36:47 +0300 |
parents | 12dbdd348bb0 |
children | bd6e95cb82b4 |
comparison
equal
deleted
inserted
replaced
19296:da16d21cf4ed | 19305:b500a663a2c7 |
---|---|
265 b 8:eebb944467c9 | 265 b 8:eebb944467c9 |
266 a branch name much longer than the default justification used by branches 7:10ff5895aa57 | 266 a branch name much longer than the default justification used by branches 7:10ff5895aa57 |
267 $ hg up -C b | 267 $ hg up -C b |
268 1 files updated, 0 files merged, 0 files removed, 0 files unresolved | 268 1 files updated, 0 files merged, 0 files removed, 0 files unresolved |
269 $ hg commit -d '9 0' --close-branch -m 'close this part branch too' | 269 $ hg commit -d '9 0' --close-branch -m 'close this part branch too' |
270 | |
271 $ hg commit -d '9 0' --close-branch -m 're-closing this branch' | 270 $ hg commit -d '9 0' --close-branch -m 're-closing this branch' |
271 abort: can only close branch heads | |
272 [255] | |
273 | |
272 $ hg log -r tip --debug | 274 $ hg log -r tip --debug |
273 changeset: 13:c2601d54b1427e99506bee25a566ef3a5963af0b | 275 changeset: 12:e3d49c0575d8fc2cb1cd6859c747c14f5f6d499f |
274 branch: b | 276 branch: b |
275 tag: tip | 277 tag: tip |
276 phase: draft | 278 phase: draft |
277 parent: 12:e3d49c0575d8fc2cb1cd6859c747c14f5f6d499f | 279 parent: 8:eebb944467c9fb9651ed232aeaf31b3c0a7fc6c1 |
278 parent: -1:0000000000000000000000000000000000000000 | 280 parent: -1:0000000000000000000000000000000000000000 |
279 manifest: 8:6f9ed32d2b310e391a4f107d5f0f071df785bfee | 281 manifest: 8:6f9ed32d2b310e391a4f107d5f0f071df785bfee |
280 user: test | 282 user: test |
281 date: Thu Jan 01 00:00:09 1970 +0000 | 283 date: Thu Jan 01 00:00:09 1970 +0000 |
282 extra: branch=b | 284 extra: branch=b |
283 extra: close=1 | 285 extra: close=1 |
284 description: | 286 description: |
285 re-closing this branch | 287 close this part branch too |
286 | 288 |
287 | 289 |
288 $ hg rollback | |
289 repository tip rolled back to revision 12 (undo commit) | |
290 working directory now based on revision 12 | |
291 | |
292 --- b branch should be inactive | 290 --- b branch should be inactive |
293 | 291 |
294 $ hg branches | 292 $ hg branches |
295 a branch name much longer than the default justification used by branches 7:10ff5895aa57 | 293 a branch name much longer than the default justification used by branches 7:10ff5895aa57 |
296 c 6:589736a22561 (inactive) | 294 c 6:589736a22561 (inactive) |