##// END OF EJS Templates
rebase: choose default destination the same way as 'hg merge' (BC)...
rebase: choose default destination the same way as 'hg merge' (BC) This changeset finally make 'hg rebase' choose its default destination using the same logic as 'hg merge'. The previous default was "tipmost changeset on the current branch", the new default is "the other head if there is only one". This change has multiple consequences: - Multiple tests which were not rebasing anything (rebasing from tipmost head) are now rebasing on the other "lower" branch. This is the expected new behavior. - A test is now explicitly aborting when there is too many heads on the branch. This is the expected behavior. - We gained a better detection of the "nothing to rebase" case while performing 'hg pull --rebase' so the message have been updated. Making clearer than an update was performed and why. This is beneficial side-effect. - Rebasing from an active bookmark will behave the same as 'hg merge' from a bookmark.

File last commit:

r28021:d0d805df default
r28189:fac3a24b default
Show More
test-merge-force.t
795 lines | 29.4 KiB | text/troff | Tads3Lexer
/ tests / test-merge-force.t
Martin von Zweigbergk
merge: add more thorough tests for --force...
r23449 Set up a base, local, and remote changeset, as well as the working copy state.
Files names are of the form base_remote_local_working-copy. For example,
content1_content2_content1_content2-untracked represents a
file that was modified in the remote changeset, left untouched in the
local changeset, and then modified in the working copy to match the
remote content, then finally forgotten.
Siddharth Agarwal
merge: move almost all change/delete conflicts to resolve phase (BC) (API)...
r27137 $ hg init repo
$ cd repo
Adrian Buehlmann
tests: unify test-merge-force
r12256
Martin von Zweigbergk
merge: add more thorough tests for --force...
r23449 Create base changeset
$ python $TESTDIR/generate-working-copy-states.py state 3 1
$ hg addremove -q --similarity 0
$ hg commit -qm 'base'
Create remote changeset
$ python $TESTDIR/generate-working-copy-states.py state 3 2
$ hg addremove -q --similarity 0
$ hg commit -qm 'remote'
Create local changeset
$ hg update -q 0
$ python $TESTDIR/generate-working-copy-states.py state 3 3
$ hg addremove -q --similarity 0
$ hg commit -qm 'local'
Set up working directory
$ python $TESTDIR/generate-working-copy-states.py state 3 wc
$ hg addremove -q --similarity 0
$ hg forget *_*_*_*-untracked
$ rm *_*_*_missing-*
Adrian Buehlmann
tests: unify test-merge-force
r12256
Martin von Zweigbergk
merge: add more thorough tests for --force...
r23449 $ hg status -A
M content1_content1_content1_content4-tracked
M content1_content1_content3_content1-tracked
M content1_content1_content3_content4-tracked
M content1_content2_content1_content2-tracked
M content1_content2_content1_content4-tracked
M content1_content2_content2_content1-tracked
M content1_content2_content2_content4-tracked
M content1_content2_content3_content1-tracked
M content1_content2_content3_content2-tracked
M content1_content2_content3_content4-tracked
M content1_missing_content1_content4-tracked
M content1_missing_content3_content1-tracked
M content1_missing_content3_content4-tracked
M missing_content2_content2_content4-tracked
M missing_content2_content3_content2-tracked
M missing_content2_content3_content4-tracked
M missing_missing_content3_content4-tracked
A content1_content1_missing_content1-tracked
A content1_content1_missing_content4-tracked
A content1_content2_missing_content1-tracked
A content1_content2_missing_content2-tracked
A content1_content2_missing_content4-tracked
A content1_missing_missing_content1-tracked
A content1_missing_missing_content4-tracked
A missing_content2_missing_content2-tracked
A missing_content2_missing_content4-tracked
A missing_missing_missing_content4-tracked
R content1_content1_content1_content1-untracked
R content1_content1_content1_content4-untracked
R content1_content1_content1_missing-untracked
R content1_content1_content3_content1-untracked
R content1_content1_content3_content3-untracked
R content1_content1_content3_content4-untracked
R content1_content1_content3_missing-untracked
R content1_content2_content1_content1-untracked
R content1_content2_content1_content2-untracked
R content1_content2_content1_content4-untracked
R content1_content2_content1_missing-untracked
R content1_content2_content2_content1-untracked
R content1_content2_content2_content2-untracked
R content1_content2_content2_content4-untracked
R content1_content2_content2_missing-untracked
R content1_content2_content3_content1-untracked
R content1_content2_content3_content2-untracked
R content1_content2_content3_content3-untracked
R content1_content2_content3_content4-untracked
R content1_content2_content3_missing-untracked
R content1_missing_content1_content1-untracked
R content1_missing_content1_content4-untracked
R content1_missing_content1_missing-untracked
R content1_missing_content3_content1-untracked
R content1_missing_content3_content3-untracked
R content1_missing_content3_content4-untracked
R content1_missing_content3_missing-untracked
R missing_content2_content2_content2-untracked
R missing_content2_content2_content4-untracked
R missing_content2_content2_missing-untracked
R missing_content2_content3_content2-untracked
R missing_content2_content3_content3-untracked
R missing_content2_content3_content4-untracked
R missing_content2_content3_missing-untracked
R missing_missing_content3_content3-untracked
R missing_missing_content3_content4-untracked
R missing_missing_content3_missing-untracked
! content1_content1_content1_missing-tracked
! content1_content1_content3_missing-tracked
! content1_content1_missing_missing-tracked
! content1_content2_content1_missing-tracked
! content1_content2_content2_missing-tracked
! content1_content2_content3_missing-tracked
! content1_content2_missing_missing-tracked
! content1_missing_content1_missing-tracked
! content1_missing_content3_missing-tracked
! content1_missing_missing_missing-tracked
! missing_content2_content2_missing-tracked
! missing_content2_content3_missing-tracked
! missing_content2_missing_missing-tracked
! missing_missing_content3_missing-tracked
! missing_missing_missing_missing-tracked
? content1_content1_missing_content1-untracked
? content1_content1_missing_content4-untracked
? content1_content2_missing_content1-untracked
? content1_content2_missing_content2-untracked
? content1_content2_missing_content4-untracked
? content1_missing_missing_content1-untracked
? content1_missing_missing_content4-untracked
? missing_content2_missing_content2-untracked
? missing_content2_missing_content4-untracked
? missing_missing_missing_content4-untracked
C content1_content1_content1_content1-tracked
C content1_content1_content3_content3-tracked
C content1_content2_content1_content1-tracked
C content1_content2_content2_content2-tracked
C content1_content2_content3_content3-tracked
C content1_missing_content1_content1-tracked
C content1_missing_content3_content3-tracked
C missing_content2_content2_content2-tracked
C missing_content2_content3_content3-tracked
C missing_missing_content3_content3-tracked
Merge with remote
Adrian Buehlmann
tests: unify test-merge-force
r12256
Martin von Zweigbergk
merge: add more thorough tests for --force...
r23449 # Notes:
# - local and remote changed content1_content2_*_content2-untracked
# in the same way, so it could potentially be left alone
Adrian Buehlmann
tests: unify test-merge-force
r12256
Siddharth Agarwal
test-merge-force: add tests for merge.checkunknown=warn...
r28021 $ hg merge -f --tool internal:merge3 'desc("remote")' 2>&1 | tee $TESTTMP/merge-output-1
Martin von Zweigbergk
merge: add more thorough tests for --force...
r23449 local changed content1_missing_content1_content4-tracked which remote deleted
Siddharth Agarwal
filemerge: default change/delete conflicts to 'leave unresolved' (BC)...
r27599 use (c)hanged version, (d)elete, or leave (u)nresolved? u
Martin von Zweigbergk
merge: add more thorough tests for --force...
r23449 local changed content1_missing_content3_content3-tracked which remote deleted
Siddharth Agarwal
filemerge: default change/delete conflicts to 'leave unresolved' (BC)...
r27599 use (c)hanged version, (d)elete, or leave (u)nresolved? u
Martin von Zweigbergk
merge: add more thorough tests for --force...
r23449 local changed content1_missing_content3_content4-tracked which remote deleted
Siddharth Agarwal
filemerge: default change/delete conflicts to 'leave unresolved' (BC)...
r27599 use (c)hanged version, (d)elete, or leave (u)nresolved? u
Martin von Zweigbergk
merge: add more thorough tests for --force...
r23449 local changed content1_missing_missing_content4-tracked which remote deleted
Siddharth Agarwal
filemerge: default change/delete conflicts to 'leave unresolved' (BC)...
r27599 use (c)hanged version, (d)elete, or leave (u)nresolved? u
Martin von Zweigbergk
merge: add more thorough tests for --force...
r23449 remote changed content1_content2_content1_content1-untracked which local deleted
Siddharth Agarwal
filemerge: default change/delete conflicts to 'leave unresolved' (BC)...
r27599 use (c)hanged version, leave (d)eleted, or leave (u)nresolved? u
Martin von Zweigbergk
merge: add more thorough tests for --force...
r23449 remote changed content1_content2_content1_content2-untracked which local deleted
Siddharth Agarwal
filemerge: default change/delete conflicts to 'leave unresolved' (BC)...
r27599 use (c)hanged version, leave (d)eleted, or leave (u)nresolved? u
Martin von Zweigbergk
merge: add more thorough tests for --force...
r23449 remote changed content1_content2_content1_content4-untracked which local deleted
Siddharth Agarwal
filemerge: default change/delete conflicts to 'leave unresolved' (BC)...
r27599 use (c)hanged version, leave (d)eleted, or leave (u)nresolved? u
Martin von Zweigbergk
merge: add more thorough tests for --force...
r23449 remote changed content1_content2_content1_missing-tracked which local deleted
Siddharth Agarwal
filemerge: default change/delete conflicts to 'leave unresolved' (BC)...
r27599 use (c)hanged version, leave (d)eleted, or leave (u)nresolved? u
Martin von Zweigbergk
merge: add more thorough tests for --force...
r23449 remote changed content1_content2_content1_missing-untracked which local deleted
Siddharth Agarwal
filemerge: default change/delete conflicts to 'leave unresolved' (BC)...
r27599 use (c)hanged version, leave (d)eleted, or leave (u)nresolved? u
Martin von Zweigbergk
merge: add more thorough tests for --force...
r23449 remote changed content1_content2_content2_content1-untracked which local deleted
Siddharth Agarwal
filemerge: default change/delete conflicts to 'leave unresolved' (BC)...
r27599 use (c)hanged version, leave (d)eleted, or leave (u)nresolved? u
Martin von Zweigbergk
merge: add more thorough tests for --force...
r23449 remote changed content1_content2_content2_content2-untracked which local deleted
Siddharth Agarwal
filemerge: default change/delete conflicts to 'leave unresolved' (BC)...
r27599 use (c)hanged version, leave (d)eleted, or leave (u)nresolved? u
Martin von Zweigbergk
merge: add more thorough tests for --force...
r23449 remote changed content1_content2_content2_content4-untracked which local deleted
Siddharth Agarwal
filemerge: default change/delete conflicts to 'leave unresolved' (BC)...
r27599 use (c)hanged version, leave (d)eleted, or leave (u)nresolved? u
Martin von Zweigbergk
merge: add more thorough tests for --force...
r23449 remote changed content1_content2_content2_missing-tracked which local deleted
Siddharth Agarwal
filemerge: default change/delete conflicts to 'leave unresolved' (BC)...
r27599 use (c)hanged version, leave (d)eleted, or leave (u)nresolved? u
Martin von Zweigbergk
merge: add more thorough tests for --force...
r23449 remote changed content1_content2_content2_missing-untracked which local deleted
Siddharth Agarwal
filemerge: default change/delete conflicts to 'leave unresolved' (BC)...
r27599 use (c)hanged version, leave (d)eleted, or leave (u)nresolved? u
Martin von Zweigbergk
merge: add more thorough tests for --force...
r23449 remote changed content1_content2_content3_content1-untracked which local deleted
Siddharth Agarwal
filemerge: default change/delete conflicts to 'leave unresolved' (BC)...
r27599 use (c)hanged version, leave (d)eleted, or leave (u)nresolved? u
Martin von Zweigbergk
merge: add more thorough tests for --force...
r23449 remote changed content1_content2_content3_content2-untracked which local deleted
Siddharth Agarwal
filemerge: default change/delete conflicts to 'leave unresolved' (BC)...
r27599 use (c)hanged version, leave (d)eleted, or leave (u)nresolved? u
Martin von Zweigbergk
merge: add more thorough tests for --force...
r23449 remote changed content1_content2_content3_content3-untracked which local deleted
Siddharth Agarwal
filemerge: default change/delete conflicts to 'leave unresolved' (BC)...
r27599 use (c)hanged version, leave (d)eleted, or leave (u)nresolved? u
Martin von Zweigbergk
merge: add more thorough tests for --force...
r23449 remote changed content1_content2_content3_content4-untracked which local deleted
Siddharth Agarwal
filemerge: default change/delete conflicts to 'leave unresolved' (BC)...
r27599 use (c)hanged version, leave (d)eleted, or leave (u)nresolved? u
Martin von Zweigbergk
merge: add more thorough tests for --force...
r23449 remote changed content1_content2_content3_missing-tracked which local deleted
Siddharth Agarwal
filemerge: default change/delete conflicts to 'leave unresolved' (BC)...
r27599 use (c)hanged version, leave (d)eleted, or leave (u)nresolved? u
Martin von Zweigbergk
merge: add more thorough tests for --force...
r23449 remote changed content1_content2_content3_missing-untracked which local deleted
Siddharth Agarwal
filemerge: default change/delete conflicts to 'leave unresolved' (BC)...
r27599 use (c)hanged version, leave (d)eleted, or leave (u)nresolved? u
Martin von Zweigbergk
merge: add more thorough tests for --force...
r23449 remote changed content1_content2_missing_content1-untracked which local deleted
Siddharth Agarwal
filemerge: default change/delete conflicts to 'leave unresolved' (BC)...
r27599 use (c)hanged version, leave (d)eleted, or leave (u)nresolved? u
Martin von Zweigbergk
merge: add more thorough tests for --force...
r23449 remote changed content1_content2_missing_content2-untracked which local deleted
Siddharth Agarwal
filemerge: default change/delete conflicts to 'leave unresolved' (BC)...
r27599 use (c)hanged version, leave (d)eleted, or leave (u)nresolved? u
Martin von Zweigbergk
merge: add more thorough tests for --force...
r23449 remote changed content1_content2_missing_content4-untracked which local deleted
Siddharth Agarwal
filemerge: default change/delete conflicts to 'leave unresolved' (BC)...
r27599 use (c)hanged version, leave (d)eleted, or leave (u)nresolved? u
Martin von Zweigbergk
merge: add more thorough tests for --force...
r23449 remote changed content1_content2_missing_missing-tracked which local deleted
Siddharth Agarwal
filemerge: default change/delete conflicts to 'leave unresolved' (BC)...
r27599 use (c)hanged version, leave (d)eleted, or leave (u)nresolved? u
Martin von Zweigbergk
merge: add more thorough tests for --force...
r23449 remote changed content1_content2_missing_missing-untracked which local deleted
Siddharth Agarwal
filemerge: default change/delete conflicts to 'leave unresolved' (BC)...
r27599 use (c)hanged version, leave (d)eleted, or leave (u)nresolved? u
Martin von Zweigbergk
merge: add more thorough tests for --force...
r23449 merging content1_content2_content1_content4-tracked
merging content1_content2_content2_content1-tracked
merging content1_content2_content2_content4-tracked
merging content1_content2_content3_content1-tracked
merging content1_content2_content3_content3-tracked
merging content1_content2_content3_content4-tracked
merging content1_content2_missing_content1-tracked
merging content1_content2_missing_content4-tracked
Siddharth Agarwal
merge.mergestate: perform all premerges before any merges (BC)...
r26618 merging missing_content2_content2_content4-tracked
merging missing_content2_content3_content3-tracked
merging missing_content2_content3_content4-tracked
merging missing_content2_missing_content4-tracked
merging missing_content2_missing_content4-untracked
warning: conflicts while merging content1_content2_content1_content4-tracked! (edit, then use 'hg resolve --mark')
warning: conflicts while merging content1_content2_content2_content4-tracked! (edit, then use 'hg resolve --mark')
warning: conflicts while merging content1_content2_content3_content3-tracked! (edit, then use 'hg resolve --mark')
warning: conflicts while merging content1_content2_content3_content4-tracked! (edit, then use 'hg resolve --mark')
Siddharth Agarwal
simplemerge: move conflict warning message to filemerge...
r26614 warning: conflicts while merging content1_content2_missing_content4-tracked! (edit, then use 'hg resolve --mark')
warning: conflicts while merging missing_content2_content2_content4-tracked! (edit, then use 'hg resolve --mark')
warning: conflicts while merging missing_content2_content3_content3-tracked! (edit, then use 'hg resolve --mark')
warning: conflicts while merging missing_content2_content3_content4-tracked! (edit, then use 'hg resolve --mark')
warning: conflicts while merging missing_content2_missing_content4-tracked! (edit, then use 'hg resolve --mark')
warning: conflicts while merging missing_content2_missing_content4-untracked! (edit, then use 'hg resolve --mark')
Siddharth Agarwal
filemerge: default change/delete conflicts to 'leave unresolved' (BC)...
r27599 18 files updated, 3 files merged, 8 files removed, 35 files unresolved
Martin von Zweigbergk
merge: add more thorough tests for --force...
r23449 use 'hg resolve' to retry unresolved file merges or 'hg update -C .' to abandon
Adrian Buehlmann
tests: unify test-merge-force
r12256
Mads Kiilerich
spelling: fixes from proofreading of spell checker issues
r23543 Check which files need to be resolved (should correspond to the output above).
Martin von Zweigbergk
merge: add more thorough tests for --force...
r23449 This should be the files for which the base (1st filename segment), the remote
(2nd segment) and the working copy (4th segment) are all different.
Mads Kiilerich
spelling: fixes from proofreading of spell checker issues
r23543 Interestingly, one untracked file got merged and added, which corresponds to the
Martin von Zweigbergk
merge: add more thorough tests for --force...
r23449 odd 'if force and branchmerge and different' case in manifestmerge().
Adrian Buehlmann
tests: unify test-merge-force
r12256
Martin von Zweigbergk
merge: add more thorough tests for --force...
r23449 $ hg resolve -l
Siddharth Agarwal
filemerge: default change/delete conflicts to 'leave unresolved' (BC)...
r27599 U content1_content2_content1_content1-untracked
U content1_content2_content1_content2-untracked
Martin von Zweigbergk
merge: add more thorough tests for --force...
r23449 U content1_content2_content1_content4-tracked
Siddharth Agarwal
filemerge: default change/delete conflicts to 'leave unresolved' (BC)...
r27599 U content1_content2_content1_content4-untracked
U content1_content2_content1_missing-tracked
U content1_content2_content1_missing-untracked
Martin von Zweigbergk
merge: add more thorough tests for --force...
r23449 R content1_content2_content2_content1-tracked
Siddharth Agarwal
filemerge: default change/delete conflicts to 'leave unresolved' (BC)...
r27599 U content1_content2_content2_content1-untracked
U content1_content2_content2_content2-untracked
Martin von Zweigbergk
merge: add more thorough tests for --force...
r23449 U content1_content2_content2_content4-tracked
Siddharth Agarwal
filemerge: default change/delete conflicts to 'leave unresolved' (BC)...
r27599 U content1_content2_content2_content4-untracked
U content1_content2_content2_missing-tracked
U content1_content2_content2_missing-untracked
Martin von Zweigbergk
merge: add more thorough tests for --force...
r23449 R content1_content2_content3_content1-tracked
Siddharth Agarwal
filemerge: default change/delete conflicts to 'leave unresolved' (BC)...
r27599 U content1_content2_content3_content1-untracked
U content1_content2_content3_content2-untracked
Martin von Zweigbergk
merge: add more thorough tests for --force...
r23449 U content1_content2_content3_content3-tracked
Siddharth Agarwal
filemerge: default change/delete conflicts to 'leave unresolved' (BC)...
r27599 U content1_content2_content3_content3-untracked
Martin von Zweigbergk
merge: add more thorough tests for --force...
r23449 U content1_content2_content3_content4-tracked
Siddharth Agarwal
filemerge: default change/delete conflicts to 'leave unresolved' (BC)...
r27599 U content1_content2_content3_content4-untracked
U content1_content2_content3_missing-tracked
U content1_content2_content3_missing-untracked
Martin von Zweigbergk
merge: add more thorough tests for --force...
r23449 R content1_content2_missing_content1-tracked
Siddharth Agarwal
filemerge: default change/delete conflicts to 'leave unresolved' (BC)...
r27599 U content1_content2_missing_content1-untracked
U content1_content2_missing_content2-untracked
Martin von Zweigbergk
merge: add more thorough tests for --force...
r23449 U content1_content2_missing_content4-tracked
Siddharth Agarwal
filemerge: default change/delete conflicts to 'leave unresolved' (BC)...
r27599 U content1_content2_missing_content4-untracked
U content1_content2_missing_missing-tracked
U content1_content2_missing_missing-untracked
U content1_missing_content1_content4-tracked
U content1_missing_content3_content3-tracked
U content1_missing_content3_content4-tracked
U content1_missing_missing_content4-tracked
Martin von Zweigbergk
merge: add more thorough tests for --force...
r23449 U missing_content2_content2_content4-tracked
U missing_content2_content3_content3-tracked
U missing_content2_content3_content4-tracked
U missing_content2_missing_content4-tracked
U missing_content2_missing_content4-untracked
Check status and file content
Some files get added (e.g. content1_content2_content1_content1-untracked)
It is not intuitive that content1_content2_content1_content4-tracked gets
merged while content1_content2_content1_content4-untracked gets overwritten.
Any *_content2_*-untracked triggers the modified/deleted prompt and then gets
overwritten.
A lot of untracked files become tracked, for example
content1_content2_content2_content2-untracked.
*_missing_missing_missing-tracked is reported as removed ('R'), which
doesn't make sense since the file did not exist in the parent, but on the
other hand, merged-in additions are reported as modifications, which is
almost as strange.
missing_missing_content3_missing-tracked becomes removed ('R'), even though
the remote side did not touch the file
Adrian Buehlmann
tests: unify test-merge-force
r12256
Siddharth Agarwal
merge: move almost all change/delete conflicts to resolve phase (BC) (API)...
r27137 $ checkstatus() {
> for f in `python $TESTDIR/generate-working-copy-states.py filelist 3`
> do
> echo
> hg status -A $f
> if test -f $f
> then
> cat $f
> else
> echo '<missing>'
> fi
> done
> }
$ checkstatus 2>&1 | tee $TESTTMP/status1
Martin von Zweigbergk
merge: add more thorough tests for --force...
r23449
C content1_content1_content1_content1-tracked
content1
R content1_content1_content1_content1-untracked
content1
M content1_content1_content1_content4-tracked
content4
R content1_content1_content1_content4-untracked
content4
! content1_content1_content1_missing-tracked
<missing>
R content1_content1_content1_missing-untracked
<missing>
M content1_content1_content3_content1-tracked
content1
R content1_content1_content3_content1-untracked
content1
C content1_content1_content3_content3-tracked
content3
R content1_content1_content3_content3-untracked
content3
M content1_content1_content3_content4-tracked
content4
R content1_content1_content3_content4-untracked
content4
! content1_content1_content3_missing-tracked
<missing>
R content1_content1_content3_missing-untracked
<missing>
A content1_content1_missing_content1-tracked
content1
? content1_content1_missing_content1-untracked
content1
A content1_content1_missing_content4-tracked
content4
? content1_content1_missing_content4-untracked
content4
! content1_content1_missing_missing-tracked
<missing>
content1_content1_missing_missing-untracked: * (glob)
<missing>
M content1_content2_content1_content1-tracked
content2
M content1_content2_content1_content1-untracked
content2
M content1_content2_content1_content2-tracked
content2
M content1_content2_content1_content2-untracked
content2
M content1_content2_content1_content4-tracked
<<<<<<< local: 0447570f1af6 - test: local
content4
||||||| base
content1
=======
content2
>>>>>>> other: 85100b8c675b - test: remote
M content1_content2_content1_content4-untracked
content2
M content1_content2_content1_missing-tracked
content2
M content1_content2_content1_missing-untracked
content2
M content1_content2_content2_content1-tracked
content2
M content1_content2_content2_content1-untracked
content2
C content1_content2_content2_content2-tracked
content2
M content1_content2_content2_content2-untracked
content2
M content1_content2_content2_content4-tracked
<<<<<<< local: 0447570f1af6 - test: local
content4
||||||| base
content1
=======
content2
>>>>>>> other: 85100b8c675b - test: remote
M content1_content2_content2_content4-untracked
content2
M content1_content2_content2_missing-tracked
content2
M content1_content2_content2_missing-untracked
content2
M content1_content2_content3_content1-tracked
content2
M content1_content2_content3_content1-untracked
content2
M content1_content2_content3_content2-tracked
content2
M content1_content2_content3_content2-untracked
content2
M content1_content2_content3_content3-tracked
<<<<<<< local: 0447570f1af6 - test: local
content3
||||||| base
content1
=======
content2
>>>>>>> other: 85100b8c675b - test: remote
M content1_content2_content3_content3-untracked
content2
M content1_content2_content3_content4-tracked
<<<<<<< local: 0447570f1af6 - test: local
content4
||||||| base
content1
=======
content2
>>>>>>> other: 85100b8c675b - test: remote
M content1_content2_content3_content4-untracked
content2
M content1_content2_content3_missing-tracked
content2
M content1_content2_content3_missing-untracked
content2
M content1_content2_missing_content1-tracked
content2
M content1_content2_missing_content1-untracked
content2
M content1_content2_missing_content2-tracked
content2
M content1_content2_missing_content2-untracked
content2
M content1_content2_missing_content4-tracked
<<<<<<< local: 0447570f1af6 - test: local
content4
||||||| base
content1
=======
content2
>>>>>>> other: 85100b8c675b - test: remote
M content1_content2_missing_content4-untracked
content2
M content1_content2_missing_missing-tracked
content2
M content1_content2_missing_missing-untracked
content2
R content1_missing_content1_content1-tracked
<missing>
R content1_missing_content1_content1-untracked
content1
M content1_missing_content1_content4-tracked
content4
R content1_missing_content1_content4-untracked
content4
R content1_missing_content1_missing-tracked
<missing>
R content1_missing_content1_missing-untracked
<missing>
R content1_missing_content3_content1-tracked
<missing>
R content1_missing_content3_content1-untracked
content1
C content1_missing_content3_content3-tracked
content3
R content1_missing_content3_content3-untracked
content3
M content1_missing_content3_content4-tracked
content4
R content1_missing_content3_content4-untracked
content4
R content1_missing_content3_missing-tracked
<missing>
R content1_missing_content3_missing-untracked
<missing>
R content1_missing_missing_content1-tracked
<missing>
? content1_missing_missing_content1-untracked
content1
A content1_missing_missing_content4-tracked
content4
? content1_missing_missing_content4-untracked
content4
R content1_missing_missing_missing-tracked
<missing>
content1_missing_missing_missing-untracked: * (glob)
<missing>
C missing_content2_content2_content2-tracked
content2
M missing_content2_content2_content2-untracked
content2
M missing_content2_content2_content4-tracked
<<<<<<< local: 0447570f1af6 - test: local
content4
||||||| base
=======
content2
>>>>>>> other: 85100b8c675b - test: remote
M missing_content2_content2_content4-untracked
content2
M missing_content2_content2_missing-tracked
content2
M missing_content2_content2_missing-untracked
content2
M missing_content2_content3_content2-tracked
content2
M missing_content2_content3_content2-untracked
content2
M missing_content2_content3_content3-tracked
<<<<<<< local: 0447570f1af6 - test: local
content3
||||||| base
=======
content2
>>>>>>> other: 85100b8c675b - test: remote
M missing_content2_content3_content3-untracked
content2
M missing_content2_content3_content4-tracked
<<<<<<< local: 0447570f1af6 - test: local
content4
||||||| base
=======
content2
>>>>>>> other: 85100b8c675b - test: remote
M missing_content2_content3_content4-untracked
content2
M missing_content2_content3_missing-tracked
content2
M missing_content2_content3_missing-untracked
content2
M missing_content2_missing_content2-tracked
content2
M missing_content2_missing_content2-untracked
content2
M missing_content2_missing_content4-tracked
<<<<<<< local: 0447570f1af6 - test: local
content4
||||||| base
=======
content2
>>>>>>> other: 85100b8c675b - test: remote
M missing_content2_missing_content4-untracked
<<<<<<< local: 0447570f1af6 - test: local
content4
||||||| base
=======
content2
>>>>>>> other: 85100b8c675b - test: remote
M missing_content2_missing_missing-tracked
content2
M missing_content2_missing_missing-untracked
content2
C missing_missing_content3_content3-tracked
content3
R missing_missing_content3_content3-untracked
content3
M missing_missing_content3_content4-tracked
content4
R missing_missing_content3_content4-untracked
content4
R missing_missing_content3_missing-tracked
<missing>
R missing_missing_content3_missing-untracked
<missing>
A missing_missing_missing_content4-tracked
content4
? missing_missing_missing_content4-untracked
content4
R missing_missing_missing_missing-tracked
<missing>
missing_missing_missing_missing-untracked: * (glob)
<missing>
Siddharth Agarwal
test-merge-force.t: check .orig files separately...
r27133
$ for f in `python $TESTDIR/generate-working-copy-states.py filelist 3`
> do
> if test -f ${f}.orig
> then
> echo ${f}.orig:
> cat ${f}.orig
> fi
> done
content1_content2_content1_content4-tracked.orig:
content4
content1_content2_content2_content4-tracked.orig:
content4
content1_content2_content3_content3-tracked.orig:
content3
content1_content2_content3_content4-tracked.orig:
content4
content1_content2_missing_content4-tracked.orig:
content4
missing_content2_content2_content4-tracked.orig:
content4
missing_content2_content3_content3-tracked.orig:
content3
missing_content2_content3_content4-tracked.orig:
content4
missing_content2_missing_content4-tracked.orig:
content4
missing_content2_missing_content4-untracked.orig:
content4
Siddharth Agarwal
merge: move almost all change/delete conflicts to resolve phase (BC) (API)...
r27137
Re-resolve and check status
$ hg resolve --unmark --all
$ hg resolve --all --tool :local
(no more unresolved files)
$ hg resolve --unmark --all
$ hg resolve --all --tool internal:merge3
remote changed content1_content2_content1_content1-untracked which local deleted
Siddharth Agarwal
filemerge: default change/delete conflicts to 'leave unresolved' (BC)...
r27599 use (c)hanged version, leave (d)eleted, or leave (u)nresolved? u
Siddharth Agarwal
merge: move almost all change/delete conflicts to resolve phase (BC) (API)...
r27137 remote changed content1_content2_content1_content2-untracked which local deleted
Siddharth Agarwal
filemerge: default change/delete conflicts to 'leave unresolved' (BC)...
r27599 use (c)hanged version, leave (d)eleted, or leave (u)nresolved? u
Siddharth Agarwal
merge: move almost all change/delete conflicts to resolve phase (BC) (API)...
r27137 merging content1_content2_content1_content4-tracked
remote changed content1_content2_content1_content4-untracked which local deleted
Siddharth Agarwal
filemerge: default change/delete conflicts to 'leave unresolved' (BC)...
r27599 use (c)hanged version, leave (d)eleted, or leave (u)nresolved? u
Siddharth Agarwal
merge: move almost all change/delete conflicts to resolve phase (BC) (API)...
r27137 remote changed content1_content2_content1_missing-tracked which local deleted
Siddharth Agarwal
filemerge: default change/delete conflicts to 'leave unresolved' (BC)...
r27599 use (c)hanged version, leave (d)eleted, or leave (u)nresolved? u
Siddharth Agarwal
merge: move almost all change/delete conflicts to resolve phase (BC) (API)...
r27137 remote changed content1_content2_content1_missing-untracked which local deleted
Siddharth Agarwal
filemerge: default change/delete conflicts to 'leave unresolved' (BC)...
r27599 use (c)hanged version, leave (d)eleted, or leave (u)nresolved? u
Siddharth Agarwal
merge: move almost all change/delete conflicts to resolve phase (BC) (API)...
r27137 merging content1_content2_content2_content1-tracked
remote changed content1_content2_content2_content1-untracked which local deleted
Siddharth Agarwal
filemerge: default change/delete conflicts to 'leave unresolved' (BC)...
r27599 use (c)hanged version, leave (d)eleted, or leave (u)nresolved? u
Siddharth Agarwal
merge: move almost all change/delete conflicts to resolve phase (BC) (API)...
r27137 remote changed content1_content2_content2_content2-untracked which local deleted
Siddharth Agarwal
filemerge: default change/delete conflicts to 'leave unresolved' (BC)...
r27599 use (c)hanged version, leave (d)eleted, or leave (u)nresolved? u
Siddharth Agarwal
merge: move almost all change/delete conflicts to resolve phase (BC) (API)...
r27137 merging content1_content2_content2_content4-tracked
remote changed content1_content2_content2_content4-untracked which local deleted
Siddharth Agarwal
filemerge: default change/delete conflicts to 'leave unresolved' (BC)...
r27599 use (c)hanged version, leave (d)eleted, or leave (u)nresolved? u
Siddharth Agarwal
merge: move almost all change/delete conflicts to resolve phase (BC) (API)...
r27137 remote changed content1_content2_content2_missing-tracked which local deleted
Siddharth Agarwal
filemerge: default change/delete conflicts to 'leave unresolved' (BC)...
r27599 use (c)hanged version, leave (d)eleted, or leave (u)nresolved? u
Siddharth Agarwal
merge: move almost all change/delete conflicts to resolve phase (BC) (API)...
r27137 remote changed content1_content2_content2_missing-untracked which local deleted
Siddharth Agarwal
filemerge: default change/delete conflicts to 'leave unresolved' (BC)...
r27599 use (c)hanged version, leave (d)eleted, or leave (u)nresolved? u
Siddharth Agarwal
merge: move almost all change/delete conflicts to resolve phase (BC) (API)...
r27137 merging content1_content2_content3_content1-tracked
remote changed content1_content2_content3_content1-untracked which local deleted
Siddharth Agarwal
filemerge: default change/delete conflicts to 'leave unresolved' (BC)...
r27599 use (c)hanged version, leave (d)eleted, or leave (u)nresolved? u
Siddharth Agarwal
merge: move almost all change/delete conflicts to resolve phase (BC) (API)...
r27137 remote changed content1_content2_content3_content2-untracked which local deleted
Siddharth Agarwal
filemerge: default change/delete conflicts to 'leave unresolved' (BC)...
r27599 use (c)hanged version, leave (d)eleted, or leave (u)nresolved? u
Siddharth Agarwal
merge: move almost all change/delete conflicts to resolve phase (BC) (API)...
r27137 merging content1_content2_content3_content3-tracked
remote changed content1_content2_content3_content3-untracked which local deleted
Siddharth Agarwal
filemerge: default change/delete conflicts to 'leave unresolved' (BC)...
r27599 use (c)hanged version, leave (d)eleted, or leave (u)nresolved? u
Siddharth Agarwal
merge: move almost all change/delete conflicts to resolve phase (BC) (API)...
r27137 merging content1_content2_content3_content4-tracked
remote changed content1_content2_content3_content4-untracked which local deleted
Siddharth Agarwal
filemerge: default change/delete conflicts to 'leave unresolved' (BC)...
r27599 use (c)hanged version, leave (d)eleted, or leave (u)nresolved? u
Siddharth Agarwal
merge: move almost all change/delete conflicts to resolve phase (BC) (API)...
r27137 remote changed content1_content2_content3_missing-tracked which local deleted
Siddharth Agarwal
filemerge: default change/delete conflicts to 'leave unresolved' (BC)...
r27599 use (c)hanged version, leave (d)eleted, or leave (u)nresolved? u
Siddharth Agarwal
merge: move almost all change/delete conflicts to resolve phase (BC) (API)...
r27137 remote changed content1_content2_content3_missing-untracked which local deleted
Siddharth Agarwal
filemerge: default change/delete conflicts to 'leave unresolved' (BC)...
r27599 use (c)hanged version, leave (d)eleted, or leave (u)nresolved? u
Siddharth Agarwal
merge: move almost all change/delete conflicts to resolve phase (BC) (API)...
r27137 merging content1_content2_missing_content1-tracked
remote changed content1_content2_missing_content1-untracked which local deleted
Siddharth Agarwal
filemerge: default change/delete conflicts to 'leave unresolved' (BC)...
r27599 use (c)hanged version, leave (d)eleted, or leave (u)nresolved? u
Siddharth Agarwal
merge: move almost all change/delete conflicts to resolve phase (BC) (API)...
r27137 remote changed content1_content2_missing_content2-untracked which local deleted
Siddharth Agarwal
filemerge: default change/delete conflicts to 'leave unresolved' (BC)...
r27599 use (c)hanged version, leave (d)eleted, or leave (u)nresolved? u
Siddharth Agarwal
merge: move almost all change/delete conflicts to resolve phase (BC) (API)...
r27137 merging content1_content2_missing_content4-tracked
remote changed content1_content2_missing_content4-untracked which local deleted
Siddharth Agarwal
filemerge: default change/delete conflicts to 'leave unresolved' (BC)...
r27599 use (c)hanged version, leave (d)eleted, or leave (u)nresolved? u
Siddharth Agarwal
merge: move almost all change/delete conflicts to resolve phase (BC) (API)...
r27137 remote changed content1_content2_missing_missing-tracked which local deleted
Siddharth Agarwal
filemerge: default change/delete conflicts to 'leave unresolved' (BC)...
r27599 use (c)hanged version, leave (d)eleted, or leave (u)nresolved? u
Siddharth Agarwal
merge: move almost all change/delete conflicts to resolve phase (BC) (API)...
r27137 remote changed content1_content2_missing_missing-untracked which local deleted
Siddharth Agarwal
filemerge: default change/delete conflicts to 'leave unresolved' (BC)...
r27599 use (c)hanged version, leave (d)eleted, or leave (u)nresolved? u
Siddharth Agarwal
merge: move almost all change/delete conflicts to resolve phase (BC) (API)...
r27137 local changed content1_missing_content1_content4-tracked which remote deleted
Siddharth Agarwal
filemerge: default change/delete conflicts to 'leave unresolved' (BC)...
r27599 use (c)hanged version, (d)elete, or leave (u)nresolved? u
Siddharth Agarwal
merge: move almost all change/delete conflicts to resolve phase (BC) (API)...
r27137 local changed content1_missing_content3_content3-tracked which remote deleted
Siddharth Agarwal
filemerge: default change/delete conflicts to 'leave unresolved' (BC)...
r27599 use (c)hanged version, (d)elete, or leave (u)nresolved? u
Siddharth Agarwal
merge: move almost all change/delete conflicts to resolve phase (BC) (API)...
r27137 local changed content1_missing_content3_content4-tracked which remote deleted
Siddharth Agarwal
filemerge: default change/delete conflicts to 'leave unresolved' (BC)...
r27599 use (c)hanged version, (d)elete, or leave (u)nresolved? u
Siddharth Agarwal
merge: move almost all change/delete conflicts to resolve phase (BC) (API)...
r27137 local changed content1_missing_missing_content4-tracked which remote deleted
Siddharth Agarwal
filemerge: default change/delete conflicts to 'leave unresolved' (BC)...
r27599 use (c)hanged version, (d)elete, or leave (u)nresolved? u
Siddharth Agarwal
merge: move almost all change/delete conflicts to resolve phase (BC) (API)...
r27137 merging missing_content2_content2_content4-tracked
merging missing_content2_content3_content3-tracked
merging missing_content2_content3_content4-tracked
merging missing_content2_missing_content4-tracked
merging missing_content2_missing_content4-untracked
warning: conflicts while merging content1_content2_content1_content4-tracked! (edit, then use 'hg resolve --mark')
warning: conflicts while merging content1_content2_content2_content4-tracked! (edit, then use 'hg resolve --mark')
warning: conflicts while merging content1_content2_content3_content3-tracked! (edit, then use 'hg resolve --mark')
warning: conflicts while merging content1_content2_content3_content4-tracked! (edit, then use 'hg resolve --mark')
warning: conflicts while merging content1_content2_missing_content4-tracked! (edit, then use 'hg resolve --mark')
warning: conflicts while merging missing_content2_content2_content4-tracked! (edit, then use 'hg resolve --mark')
warning: conflicts while merging missing_content2_content3_content3-tracked! (edit, then use 'hg resolve --mark')
warning: conflicts while merging missing_content2_content3_content4-tracked! (edit, then use 'hg resolve --mark')
warning: conflicts while merging missing_content2_missing_content4-tracked! (edit, then use 'hg resolve --mark')
warning: conflicts while merging missing_content2_missing_content4-untracked! (edit, then use 'hg resolve --mark')
[1]
$ checkstatus > $TESTTMP/status2 2>&1
Danek Duvall
tests: Solaris diff -U also emits "No differences encountered"...
r27557 $ cmp $TESTTMP/status1 $TESTTMP/status2 || diff -U8 $TESTTMP/status1 $TESTTMP/status2
Siddharth Agarwal
test-merge-force: add tests for merge.checkunknown=warn...
r28021
Set up working directory again
$ hg -q update --clean 2
$ hg --config extensions.purge= purge
$ python $TESTDIR/generate-working-copy-states.py state 3 wc
$ hg addremove -q --similarity 0
$ hg forget *_*_*_*-untracked
$ rm *_*_*_missing-*
Merge with checkunknown = warn, see that behavior is the same as before
$ hg merge -f --tool internal:merge3 'desc("remote")' --config merge.checkunknown=warn > $TESTTMP/merge-output-2 2>&1
[1]
$ cmp $TESTTMP/merge-output-1 $TESTTMP/merge-output-2 || diff -U8 $TESTTMP/merge-output-1 $TESTTMP/merge-output-2