tests/test-rebase-rename.t
changeset 23835 aa4a1672583e
parent 23518 2fb0504b8175
child 26811 d1561a422748
equal deleted inserted replaced
23834:bf07c19b4c82 23835:aa4a1672583e
    59   
    59   
    60 Rebase the revision containing the rename:
    60 Rebase the revision containing the rename:
    61 
    61 
    62   $ hg rebase -s 3 -d 2
    62   $ hg rebase -s 3 -d 2
    63   rebasing 3:73a3ee40125d "rename A" (tip)
    63   rebasing 3:73a3ee40125d "rename A" (tip)
    64   saved backup bundle to $TESTTMP/a/.hg/strip-backup/73a3ee40125d-backup.hg (glob)
    64   saved backup bundle to $TESTTMP/a/.hg/strip-backup/73a3ee40125d-1d78ebcf-backup.hg (glob)
    65 
    65 
    66   $ hg tglog
    66   $ hg tglog
    67   @  3: 'rename A'
    67   @  3: 'rename A'
    68   |
    68   |
    69   o  2: 'rename B'
    69   o  2: 'rename B'
   150   
   150   
   151 Rebase the revision containing the copy:
   151 Rebase the revision containing the copy:
   152 
   152 
   153   $ hg rebase -s 3 -d 2
   153   $ hg rebase -s 3 -d 2
   154   rebasing 3:0a8162ff18a8 "copy A" (tip)
   154   rebasing 3:0a8162ff18a8 "copy A" (tip)
   155   saved backup bundle to $TESTTMP/b/.hg/strip-backup/0a8162ff18a8-backup.hg (glob)
   155   saved backup bundle to $TESTTMP/b/.hg/strip-backup/0a8162ff18a8-dd06302a-backup.hg (glob)
   156 
   156 
   157   $ hg tglog
   157   $ hg tglog
   158   @  3: 'copy A'
   158   @  3: 'copy A'
   159   |
   159   |
   160   o  2: 'copy B'
   160   o  2: 'copy B'
   234   o  0: 'Adding file1'
   234   o  0: 'Adding file1'
   235   
   235   
   236 
   236 
   237   $ hg rebase -s 4 -d 3
   237   $ hg rebase -s 4 -d 3
   238   rebasing 4:b918d683b091 "Another unrelated change" (tip)
   238   rebasing 4:b918d683b091 "Another unrelated change" (tip)
   239   saved backup bundle to $TESTTMP/repo/.hg/strip-backup/b918d683b091-backup.hg (glob)
   239   saved backup bundle to $TESTTMP/repo/.hg/strip-backup/b918d683b091-3024bc57-backup.hg (glob)
   240 
   240 
   241   $ hg diff --stat -c .
   241   $ hg diff --stat -c .
   242    unrelated.txt |  1 +
   242    unrelated.txt |  1 +
   243    1 files changed, 1 insertions(+), 0 deletions(-)
   243    1 files changed, 1 insertions(+), 0 deletions(-)
   244 
   244 
   285 Rebase the copies on top of the unrelated change.
   285 Rebase the copies on top of the unrelated change.
   286   $ hg rebase --source 1 --dest 4
   286   $ hg rebase --source 1 --dest 4
   287   rebasing 1:79d255d24ad2 "File b created as copy of a and modified"
   287   rebasing 1:79d255d24ad2 "File b created as copy of a and modified"
   288   rebasing 2:327f772bc074 "File c created as copy of b and modified"
   288   rebasing 2:327f772bc074 "File c created as copy of b and modified"
   289   rebasing 3:421b7e82bb85 "File d created as copy of c and modified"
   289   rebasing 3:421b7e82bb85 "File d created as copy of c and modified"
   290   saved backup bundle to $TESTTMP/copy-gets-preserved/.hg/strip-backup/79d255d24ad2-backup.hg (glob)
   290   saved backup bundle to $TESTTMP/copy-gets-preserved/.hg/strip-backup/79d255d24ad2-a2265555-backup.hg (glob)
   291   $ hg update 4
   291   $ hg update 4
   292   3 files updated, 0 files merged, 0 files removed, 0 files unresolved
   292   3 files updated, 0 files merged, 0 files removed, 0 files unresolved
   293 
   293 
   294 There should still be four entries in the log for d
   294 There should still be four entries in the log for d
   295   $ hg tglog --follow d
   295   $ hg tglog --follow d
   315   merging b and c to c
   315   merging b and c to c
   316   note: rebase of 3:af74b229bc02 created no changes to commit
   316   note: rebase of 3:af74b229bc02 created no changes to commit
   317   rebasing 4:dbb9ba033561 "File d created as copy of c and modified"
   317   rebasing 4:dbb9ba033561 "File d created as copy of c and modified"
   318   merging c and d to d
   318   merging c and d to d
   319   note: rebase of 4:dbb9ba033561 created no changes to commit
   319   note: rebase of 4:dbb9ba033561 created no changes to commit
   320   saved backup bundle to $TESTTMP/copy-gets-preserved/.hg/strip-backup/68bf06433839-backup.hg (glob)
   320   saved backup bundle to $TESTTMP/copy-gets-preserved/.hg/strip-backup/68bf06433839-dde37595-backup.hg (glob)
   321   $ hg co tip
   321   $ hg co tip
   322   3 files updated, 0 files merged, 0 files removed, 0 files unresolved
   322   3 files updated, 0 files merged, 0 files removed, 0 files unresolved
   323 
   323 
   324 This should show both revision 3 and 0 since 'd' was transitively a
   324 This should show both revision 3 and 0 since 'd' was transitively a
   325 copy of 'a'.
   325 copy of 'a'.