comparison tests/test-uncommit.t @ 313:47d10459fa24

uncommit: handle bookmarks Extract the bookmarks handling code from amend and share it with uncommit.
author Patrick Mezard <patrick@mezard.eu>
date Tue, 26 Jun 2012 16:12:52 +0200
parents a7b5989d1d92
children ebd286f06879
comparison
equal deleted inserted replaced
312:a7b5989d1d92 313:47d10459fa24
115 j 115 j
116 k 116 k
117 l 117 l
118 o 118 o
119 119
120 Add a couple of bookmarks
121
122 $ glog --hidden
123 @ 3:5eb72dbe0cb4@bar(stable/draft) touncommit
124 |
125 o 2:f63b90038565@default(stable/draft) merge
126 |\
127 | o 1:f15c744d48e8@default(stable/draft) addmore
128 |
129 o 0:07f494440405@default(stable/draft) adda
130
131 $ hg bookmark -r 2 unrelated
132 $ hg bookmark touncommit-bm
133 $ hg bookmark --inactive touncommit-bm-inactive
134 $ hg bookmarks
135 * touncommit-bm 3:5eb72dbe0cb4
136 touncommit-bm-inactive 3:5eb72dbe0cb4
137 unrelated 2:f63b90038565
138
120 Prepare complicated working directory 139 Prepare complicated working directory
121 140
122 $ hg branch foo 141 $ hg branch foo
123 marked working directory as branch foo 142 marked working directory as branch foo
124 (branches are permanent and global, did you want a bookmark?) 143 (branches are permanent and global, did you want a bookmark?)
133 Test uncommit without argument, should be a no-op 152 Test uncommit without argument, should be a no-op
134 153
135 $ hg uncommit 154 $ hg uncommit
136 abort: nothing to uncommit 155 abort: nothing to uncommit
137 [255] 156 [255]
157 $ hg bookmarks
158 * touncommit-bm 3:5eb72dbe0cb4
159 touncommit-bm-inactive 3:5eb72dbe0cb4
160 unrelated 2:f63b90038565
138 161
139 Test no matches 162 Test no matches
140 163
141 $ hg uncommit --include nothere 164 $ hg uncommit --include nothere
142 abort: nothing to uncommit 165 abort: nothing to uncommit
203 |\ 226 |\
204 | o 1:f15c744d48e8@default(stable/draft) addmore 227 | o 1:f15c744d48e8@default(stable/draft) addmore
205 | 228 |
206 o 0:07f494440405@default(stable/draft) adda 229 o 0:07f494440405@default(stable/draft) adda
207 230
231 $ hg bookmarks
232 * touncommit-bm 4:e8db4aa611f6
233 touncommit-bm-inactive 4:e8db4aa611f6
234 unrelated 2:f63b90038565
208 $ hg debugsuccessors 235 $ hg debugsuccessors
209 5eb72dbe0cb4 e8db4aa611f6 236 5eb72dbe0cb4 e8db4aa611f6
210 237
211 Test phase is preserved, no local changes 238 Test phase is preserved, no local changes
212 239