Mercurial > hg
annotate tests/test-commit-interactive-curses.t @ 24385:885a573fa619
patch.pathtransform: prepend prefix even if strip is 0
Silly oversight by me.
author | Siddharth Agarwal <sid0@fb.com> |
---|---|
date | Wed, 18 Mar 2015 20:59:06 -0700 |
parents | 852801178a63 |
children | f169405c03ab |
rev | line source |
---|---|
24363
852801178a63
test-commit-interactive-curses: #require 'tic'
Matt Harbison <matt_harbison@yahoo.com>
parents:
24361
diff
changeset
|
1 #require tic |
24344
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
2 Set up a repo |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
3 |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
4 $ cat <<EOF >> $HGRCPATH |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
5 > [ui] |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
6 > interactive = true |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
7 > [experimental] |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
8 > crecord = true |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
9 > crecordtest = testModeCommands |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
10 > EOF |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
11 |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
12 $ hg init a |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
13 $ cd a |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
14 |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
15 Committing some changes but stopping on the way |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
16 |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
17 $ echo "a" > a |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
18 $ hg add a |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
19 $ cat <<EOF >testModeCommands |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
20 > TOGGLE |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
21 > X |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
22 > EOF |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
23 $ hg commit -i -m "a" -d "0 0" |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
24 no changes to record |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
25 $ hg tip |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
26 changeset: -1:000000000000 |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
27 tag: tip |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
28 user: |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
29 date: Thu Jan 01 00:00:00 1970 +0000 |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
30 |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
31 |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
32 Committing some changes |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
33 |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
34 $ cat <<EOF >testModeCommands |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
35 > X |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
36 > EOF |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
37 $ hg commit -i -m "a" -d "0 0" |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
38 $ hg tip |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
39 changeset: 0:cb9a9f314b8b |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
40 tag: tip |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
41 user: test |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
42 date: Thu Jan 01 00:00:00 1970 +0000 |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
43 summary: a |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
44 |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
45 Committing only one file |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
46 |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
47 $ echo "a" >> a |
24361
8de8cd34f2e3
tests: replace uses of 'seq' with portable 'seq.py'
Matt Harbison <matt_harbison@yahoo.com>
parents:
24344
diff
changeset
|
48 $ python $TESTDIR/seq.py 1 10 > b |
24344
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
49 $ hg add b |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
50 $ cat <<EOF >testModeCommands |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
51 > TOGGLE |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
52 > KEY_DOWN |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
53 > X |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
54 > EOF |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
55 $ hg commit -i -m "one file" -d "0 0" |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
56 $ hg tip |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
57 changeset: 1:fb2705a663ea |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
58 tag: tip |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
59 user: test |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
60 date: Thu Jan 01 00:00:00 1970 +0000 |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
61 summary: one file |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
62 |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
63 $ hg cat -r tip a |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
64 a |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
65 $ cat a |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
66 a |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
67 a |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
68 |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
69 Committing only one hunk |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
70 |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
71 - Untoggle all the hunks, go down to the second file |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
72 - unfold it |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
73 - go down to second hunk (1 for the first hunk, 1 for the first hunkline, 1 for the second hunk, 1 for the second hunklike) |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
74 - toggle the second hunk |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
75 - commit |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
76 |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
77 $ echo "x" > c |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
78 $ cat b >> c |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
79 $ echo "y" >> c |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
80 $ mv c b |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
81 $ cat <<EOF >testModeCommands |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
82 > A |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
83 > KEY_DOWN |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
84 > f |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
85 > KEY_DOWN |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
86 > KEY_DOWN |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
87 > KEY_DOWN |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
88 > KEY_DOWN |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
89 > TOGGLE |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
90 > X |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
91 > EOF |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
92 $ hg commit -i -m "one hunk" -d "0 0" |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
93 $ hg tip |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
94 changeset: 2:7d10dfe755a8 |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
95 tag: tip |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
96 user: test |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
97 date: Thu Jan 01 00:00:00 1970 +0000 |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
98 summary: one hunk |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
99 |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
100 $ hg cat -r tip b |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
101 1 |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
102 2 |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
103 3 |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
104 4 |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
105 5 |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
106 6 |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
107 7 |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
108 8 |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
109 9 |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
110 10 |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
111 y |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
112 $ cat b |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
113 x |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
114 1 |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
115 2 |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
116 3 |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
117 4 |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
118 5 |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
119 6 |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
120 7 |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
121 8 |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
122 9 |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
123 10 |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
124 y |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
125 $ hg commit -m "other hunks" |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
126 $ hg tip |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
127 changeset: 3:a6735021574d |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
128 tag: tip |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
129 user: test |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
130 date: Thu Jan 01 00:00:00 1970 +0000 |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
131 summary: other hunks |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
132 |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
133 $ hg cat -r tip b |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
134 x |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
135 1 |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
136 2 |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
137 3 |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
138 4 |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
139 5 |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
140 6 |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
141 7 |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
142 8 |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
143 9 |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
144 10 |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
145 y |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
146 |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
147 Editing patch of newly added file |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
148 |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
149 $ cat > editor.sh << '__EOF__' |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
150 > cat "$1" | sed "s/first/very/g" > tt |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
151 > mv tt "$1" |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
152 > __EOF__ |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
153 $ cat > newfile << '__EOF__' |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
154 > This is the first line |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
155 > This is the second line |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
156 > This is the third line |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
157 > __EOF__ |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
158 $ hg add newfile |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
159 $ cat <<EOF >testModeCommands |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
160 > f |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
161 > KEY_DOWN |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
162 > KEY_DOWN |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
163 > KEY_DOWN |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
164 > e |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
165 > X |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
166 > EOF |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
167 $ HGEDITOR="\"sh\" \"`pwd`/editor.sh\"" hg commit -i -d '23 0' -medit-patch-new |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
168 $ hg tip |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
169 changeset: 4:6a0a43e9eff5 |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
170 tag: tip |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
171 user: test |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
172 date: Thu Jan 01 00:00:23 1970 +0000 |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
173 summary: edit-patch-new |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
174 |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
175 $ hg cat -r tip newfile |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
176 This is the very line |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
177 This is the second line |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
178 This is the third line |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
179 |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
180 $ cat newfile |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
181 This is the first line |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
182 This is the second line |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
183 This is the third line |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
184 |
6b43baac6dfb
record: add tests for the curses recording interface
Laurent Charignon <lcharignon@fb.com>
parents:
diff
changeset
|
185 |