Show More
@@ -1,33 +1,40 b'' | |||||
1 | #!/bin/sh |
|
1 | Failed qimport of patches from files should cleanup by recording successfully | |
2 | #failed qimport of patches from files should cleanup by recording successfully |
|
2 | imported patches in series file. | |
3 | #imported patches in series file. |
|
|||
4 |
|
3 | |||
5 | echo "[extensions]" >> $HGRCPATH |
|
4 | $ echo "[extensions]" >> $HGRCPATH | |
6 | echo "mq=" >> $HGRCPATH |
|
5 | $ echo "mq=" >> $HGRCPATH | |
7 |
|
6 | $ hg init repo | ||
8 | hg init repo |
|
7 | $ cd repo | |
9 | cd repo |
|
8 | $ echo a > a | |
10 |
|
9 | $ hg ci -Am'add a' | ||
11 | echo a > a |
|
10 | adding a | |
12 | hg ci -Am'add a' |
|
11 | $ cat >b.patch<<EOF | |
|
12 | > diff --git a/a b/a | |||
|
13 | > --- a/a | |||
|
14 | > +++ b/a | |||
|
15 | > @@ -1,1 +1,2 @@ | |||
|
16 | > a | |||
|
17 | > +b | |||
|
18 | > EOF | |||
|
19 | $ echo | |||
13 |
|
20 | |||
14 | cat >b.patch<<EOF |
|
21 | ||
15 | diff --git a/a b/a |
|
22 | empty series | |
16 | --- a/a |
|
23 | ||
17 | +++ b/a |
|
24 | $ hg qseries | |
18 | @@ -1,1 +1,2 @@ |
|
25 | $ echo | |
19 | a |
|
26 | ||
20 | +b |
|
27 | ||
21 | EOF |
|
28 | qimport valid patch followed by invalid patch | |
22 |
|
29 | |||
23 | echo |
|
30 | $ hg qimport b.patch fakepatch | |
24 | echo '#empty series' |
|
31 | adding b.patch to series file | |
25 | hg qseries |
|
32 | abort: unable to read file fakepatch | |
|
33 | [255] | |||
|
34 | $ echo | |||
26 |
|
35 | |||
27 | echo |
|
36 | ||
28 | echo '#qimport valid patch followed by invalid patch' |
|
37 | valid patches before fail added to series | |
29 | hg qimport b.patch fakepatch |
|
|||
30 |
|
38 | |||
31 | echo |
|
39 | $ hg qseries | |
32 | echo '#valid patches before fail added to series' |
|
40 | b.patch | |
33 | hg qseries |
|
1 | NO CONTENT: file was removed |
|
NO CONTENT: file was removed |
General Comments 0
You need to be logged in to leave comments.
Login now