Skip to content
Snippets Groups Projects
Commit dc342071 authored by Kyle Lippincott's avatar Kyle Lippincott
Browse files

amend: add test showing poor behavior when copies are involved

Differential Revision: https://phab.mercurial-scm.org/D12624
parent 77b5a190
No related branches found
No related tags found
No related merge requests found
......@@ -609,3 +609,20 @@
> hg status
> fi
OK.
Amending a commit that has copies but not specifying those copies shouldn't
cause them to be lost
$ cd $TESTTMP
$ hg init dont-lose-copies; cd dont-lose-copies
$ echo r0 > r0; hg commit -qAm "r0"
$ hg cp r0 r0_copied; hg commit -qm "copy r0"
$ echo hi > new_file_amend_me
$ hg status --change . --copies
A r0_copied
r0
$ hg amend -qA new_file_amend_me
$ hg status --change . --copies
A new_file_amend_me
A r0_copied
r0 (missing-correct-output !)
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment