##// END OF EJS Templates
tests: unify test-resolve
Nicolas Dumazet -
r12117:a40372c1 default
parent child Browse files
Show More
@@ -1,33 +1,43 b''
1 #!/bin/sh
1 test that a commit clears the merge state.
2 2
3 # test that a commit clears the merge state.
3 $ hg init repo
4 $ cd repo
5
6 $ echo foo > file
7 $ hg commit -Am 'add file'
8 adding file
4 9
5 hg init repo
6 cd repo
10 $ echo bar >> file
11 $ hg commit -Am 'append bar'
12
13
14 create a second head
7 15
8 echo foo > file
9 hg commit -Am 'add file'
10
11 echo bar >> file
12 hg commit -Am 'append bar'
16 $ hg up -C 0
17 1 files updated, 0 files merged, 0 files removed, 0 files unresolved
18 $ echo baz >> file
19 $ hg commit -Am 'append baz'
20 created new head
13 21
14 echo % create a second head
15 hg up -C 0
16 echo baz >> file
17 hg commit -Am 'append baz'
22 failing merge
18 23
19 echo % failing merge
20 HGMERGE=internal:fail hg merge
24 $ HGMERGE=internal:fail hg merge
25 0 files updated, 0 files merged, 0 files removed, 1 files unresolved
26 use 'hg resolve' to retry unresolved file merges or 'hg update -C' to abandon
27
28 $ echo resolved > file
29 $ hg resolve -m file
30 $ hg commit -m 'resolved'
21 31
22 echo resolved > file
23 hg resolve -m file
24 hg commit -m 'resolved'
32 resolve -l, should be empty
33
34 $ hg resolve -l
35
36 test crashed merge with empty mergestate
25 37
26 echo % resolve -l, should be empty
27 hg resolve -l
38 $ mkdir .hg/merge
39 $ touch .hg/merge/state
28 40
29 # test crashed merge with empty mergestate
30 mkdir .hg/merge
31 touch .hg/merge/state
32 echo % resolve -l, should be empty
33 hg resolve -l
41 resolve -l, should be empty
42
43 $ hg resolve -l
1 NO CONTENT: file was removed
General Comments 0
You need to be logged in to leave comments. Login now