3 0ebf8283 2019-07-24 stsp # Copyright (c) 2019 Stefan Sperling <stsp@openbsd.org>
5 0ebf8283 2019-07-24 stsp # Permission to use, copy, modify, and distribute this software for any
6 0ebf8283 2019-07-24 stsp # purpose with or without fee is hereby granted, provided that the above
7 0ebf8283 2019-07-24 stsp # copyright notice and this permission notice appear in all copies.
9 0ebf8283 2019-07-24 stsp # THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
10 0ebf8283 2019-07-24 stsp # WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
11 0ebf8283 2019-07-24 stsp # MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
12 0ebf8283 2019-07-24 stsp # ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
13 0ebf8283 2019-07-24 stsp # WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
14 0ebf8283 2019-07-24 stsp # ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
15 0ebf8283 2019-07-24 stsp # OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
17 0ebf8283 2019-07-24 stsp . ./common.sh
19 0ebf8283 2019-07-24 stsp function test_histedit_no_op {
20 0ebf8283 2019-07-24 stsp local testroot=`test_init histedit_no_op`
22 0ebf8283 2019-07-24 stsp local orig_commit=`git_show_head $testroot/repo`
24 0ebf8283 2019-07-24 stsp echo "modified alpha on master" > $testroot/repo/alpha
25 0ebf8283 2019-07-24 stsp (cd $testroot/repo && git rm -q beta)
26 0ebf8283 2019-07-24 stsp echo "new file on master" > $testroot/repo/epsilon/new
27 0ebf8283 2019-07-24 stsp (cd $testroot/repo && git add epsilon/new)
28 0ebf8283 2019-07-24 stsp git_commit $testroot/repo -m "committing changes"
29 0ebf8283 2019-07-24 stsp local old_commit1=`git_show_head $testroot/repo`
31 0ebf8283 2019-07-24 stsp echo "modified zeta on master" > $testroot/repo/epsilon/zeta
32 0ebf8283 2019-07-24 stsp git_commit $testroot/repo -m "committing to zeta on master"
33 0ebf8283 2019-07-24 stsp local old_commit2=`git_show_head $testroot/repo`
35 86ac67ee 2019-07-25 stsp got diff -r $testroot/repo $orig_commit $old_commit2 \
36 86ac67ee 2019-07-25 stsp > $testroot/diff.expected
38 0ebf8283 2019-07-24 stsp got checkout -c $orig_commit $testroot/repo $testroot/wt > /dev/null
40 0ebf8283 2019-07-24 stsp if [ "$ret" != "0" ]; then
41 0ebf8283 2019-07-24 stsp test_done "$testroot" "$ret"
45 0ebf8283 2019-07-24 stsp echo "pick $old_commit1" > $testroot/histedit-script
46 0ebf8283 2019-07-24 stsp echo "pick $old_commit2" >> $testroot/histedit-script
48 0ebf8283 2019-07-24 stsp (cd $testroot/wt && got histedit -F $testroot/histedit-script \
49 0ebf8283 2019-07-24 stsp > $testroot/stdout)
51 0ebf8283 2019-07-24 stsp local new_commit1=`git_show_parent_commit $testroot/repo`
52 0ebf8283 2019-07-24 stsp local new_commit2=`git_show_head $testroot/repo`
54 0ebf8283 2019-07-24 stsp local short_old_commit1=`trim_obj_id 28 $old_commit1`
55 0ebf8283 2019-07-24 stsp local short_old_commit2=`trim_obj_id 28 $old_commit2`
56 0ebf8283 2019-07-24 stsp local short_new_commit1=`trim_obj_id 28 $new_commit1`
57 0ebf8283 2019-07-24 stsp local short_new_commit2=`trim_obj_id 28 $new_commit2`
59 0ebf8283 2019-07-24 stsp echo "G alpha" > $testroot/stdout.expected
60 0ebf8283 2019-07-24 stsp echo "D beta" >> $testroot/stdout.expected
61 0ebf8283 2019-07-24 stsp echo "A epsilon/new" >> $testroot/stdout.expected
62 0ebf8283 2019-07-24 stsp echo "$short_old_commit1 -> $short_new_commit1: committing changes" \
63 0ebf8283 2019-07-24 stsp >> $testroot/stdout.expected
64 0ebf8283 2019-07-24 stsp echo "G epsilon/zeta" >> $testroot/stdout.expected
65 0ebf8283 2019-07-24 stsp echo -n "$short_old_commit2 -> $short_new_commit2: " \
66 0ebf8283 2019-07-24 stsp >> $testroot/stdout.expected
67 0ebf8283 2019-07-24 stsp echo "committing to zeta on master" >> $testroot/stdout.expected
68 0ebf8283 2019-07-24 stsp echo "Switching work tree to refs/heads/master" \
69 0ebf8283 2019-07-24 stsp >> $testroot/stdout.expected
71 0ebf8283 2019-07-24 stsp cmp -s $testroot/stdout.expected $testroot/stdout
73 0ebf8283 2019-07-24 stsp if [ "$ret" != "0" ]; then
74 0ebf8283 2019-07-24 stsp diff -u $testroot/stdout.expected $testroot/stdout
75 0ebf8283 2019-07-24 stsp test_done "$testroot" "$ret"
79 0ebf8283 2019-07-24 stsp echo "modified alpha on master" > $testroot/content.expected
80 0ebf8283 2019-07-24 stsp cat $testroot/wt/alpha > $testroot/content
81 0ebf8283 2019-07-24 stsp cmp -s $testroot/content.expected $testroot/content
83 0ebf8283 2019-07-24 stsp if [ "$ret" != "0" ]; then
84 0ebf8283 2019-07-24 stsp diff -u $testroot/content.expected $testroot/content
85 0ebf8283 2019-07-24 stsp test_done "$testroot" "$ret"
89 0ebf8283 2019-07-24 stsp if [ -e $testroot/wt/beta ]; then
90 0ebf8283 2019-07-24 stsp echo "removed file beta still exists on disk" >&2
91 0ebf8283 2019-07-24 stsp test_done "$testroot" "1"
95 0ebf8283 2019-07-24 stsp echo "new file on master" > $testroot/content.expected
96 0ebf8283 2019-07-24 stsp cat $testroot/wt/epsilon/new > $testroot/content
97 0ebf8283 2019-07-24 stsp cmp -s $testroot/content.expected $testroot/content
99 0ebf8283 2019-07-24 stsp if [ "$ret" != "0" ]; then
100 0ebf8283 2019-07-24 stsp diff -u $testroot/content.expected $testroot/content
101 0ebf8283 2019-07-24 stsp test_done "$testroot" "$ret"
105 0ebf8283 2019-07-24 stsp (cd $testroot/wt && got status > $testroot/stdout)
107 0ebf8283 2019-07-24 stsp echo -n > $testroot/stdout.expected
108 0ebf8283 2019-07-24 stsp cmp -s $testroot/stdout.expected $testroot/stdout
110 0ebf8283 2019-07-24 stsp if [ "$ret" != "0" ]; then
111 0ebf8283 2019-07-24 stsp diff -u $testroot/stdout.expected $testroot/stdout
112 0ebf8283 2019-07-24 stsp test_done "$testroot" "$ret"
116 0ebf8283 2019-07-24 stsp (cd $testroot/wt && got log -l3 | grep ^commit > $testroot/stdout)
117 0ebf8283 2019-07-24 stsp echo "commit $new_commit2 (master)" > $testroot/stdout.expected
118 0ebf8283 2019-07-24 stsp echo "commit $new_commit1" >> $testroot/stdout.expected
119 0ebf8283 2019-07-24 stsp echo "commit $orig_commit" >> $testroot/stdout.expected
120 0ebf8283 2019-07-24 stsp cmp -s $testroot/stdout.expected $testroot/stdout
122 0ebf8283 2019-07-24 stsp if [ "$ret" != "0" ]; then
123 0ebf8283 2019-07-24 stsp diff -u $testroot/stdout.expected $testroot/stdout
124 86ac67ee 2019-07-25 stsp test_done "$testroot" "$ret"
128 86ac67ee 2019-07-25 stsp got diff -r $testroot/repo $orig_commit $new_commit2 \
129 86ac67ee 2019-07-25 stsp > $testroot/diff
130 86ac67ee 2019-07-25 stsp sed -i -e "s/$old_commit2/$new_commit2/" $testroot/diff.expected
131 86ac67ee 2019-07-25 stsp cmp -s $testroot/diff.expected $testroot/diff
133 86ac67ee 2019-07-25 stsp if [ "$ret" != "0" ]; then
134 86ac67ee 2019-07-25 stsp diff -u $testroot/diff.expected $testroot/diff
136 0ebf8283 2019-07-24 stsp test_done "$testroot" "$ret"
139 0ebf8283 2019-07-24 stsp function test_histedit_swap {
140 0ebf8283 2019-07-24 stsp local testroot=`test_init histedit_swap`
142 0ebf8283 2019-07-24 stsp local orig_commit=`git_show_head $testroot/repo`
144 0ebf8283 2019-07-24 stsp echo "modified alpha on master" > $testroot/repo/alpha
145 0ebf8283 2019-07-24 stsp (cd $testroot/repo && git rm -q beta)
146 0ebf8283 2019-07-24 stsp echo "new file on master" > $testroot/repo/epsilon/new
147 0ebf8283 2019-07-24 stsp (cd $testroot/repo && git add epsilon/new)
148 0ebf8283 2019-07-24 stsp git_commit $testroot/repo -m "committing changes"
149 0ebf8283 2019-07-24 stsp local old_commit1=`git_show_head $testroot/repo`
151 0ebf8283 2019-07-24 stsp echo "modified zeta on master" > $testroot/repo/epsilon/zeta
152 0ebf8283 2019-07-24 stsp git_commit $testroot/repo -m "committing to zeta on master"
153 0ebf8283 2019-07-24 stsp local old_commit2=`git_show_head $testroot/repo`
155 86ac67ee 2019-07-25 stsp got diff -r $testroot/repo $orig_commit $old_commit2 \
156 86ac67ee 2019-07-25 stsp > $testroot/diff.expected
158 0ebf8283 2019-07-24 stsp got checkout -c $orig_commit $testroot/repo $testroot/wt > /dev/null
160 0ebf8283 2019-07-24 stsp if [ "$ret" != "0" ]; then
161 0ebf8283 2019-07-24 stsp test_done "$testroot" "$ret"
165 0ebf8283 2019-07-24 stsp echo "pick $old_commit2" > $testroot/histedit-script
166 0ebf8283 2019-07-24 stsp echo "pick $old_commit1" >> $testroot/histedit-script
168 0ebf8283 2019-07-24 stsp (cd $testroot/wt && got histedit -F $testroot/histedit-script \
169 0ebf8283 2019-07-24 stsp > $testroot/stdout)
171 0ebf8283 2019-07-24 stsp local new_commit2=`git_show_parent_commit $testroot/repo`
172 0ebf8283 2019-07-24 stsp local new_commit1=`git_show_head $testroot/repo`
174 0ebf8283 2019-07-24 stsp local short_old_commit1=`trim_obj_id 28 $old_commit1`
175 0ebf8283 2019-07-24 stsp local short_old_commit2=`trim_obj_id 28 $old_commit2`
176 0ebf8283 2019-07-24 stsp local short_new_commit1=`trim_obj_id 28 $new_commit1`
177 0ebf8283 2019-07-24 stsp local short_new_commit2=`trim_obj_id 28 $new_commit2`
179 0ebf8283 2019-07-24 stsp echo "G epsilon/zeta" > $testroot/stdout.expected
180 0ebf8283 2019-07-24 stsp echo -n "$short_old_commit2 -> $short_new_commit2: " \
181 0ebf8283 2019-07-24 stsp >> $testroot/stdout.expected
182 0ebf8283 2019-07-24 stsp echo "committing to zeta on master" >> $testroot/stdout.expected
183 0ebf8283 2019-07-24 stsp echo "G alpha" >> $testroot/stdout.expected
184 0ebf8283 2019-07-24 stsp echo "D beta" >> $testroot/stdout.expected
185 0ebf8283 2019-07-24 stsp echo "A epsilon/new" >> $testroot/stdout.expected
186 0ebf8283 2019-07-24 stsp echo "$short_old_commit1 -> $short_new_commit1: committing changes" \
187 0ebf8283 2019-07-24 stsp >> $testroot/stdout.expected
188 0ebf8283 2019-07-24 stsp echo "Switching work tree to refs/heads/master" \
189 0ebf8283 2019-07-24 stsp >> $testroot/stdout.expected
191 0ebf8283 2019-07-24 stsp cmp -s $testroot/stdout.expected $testroot/stdout
193 0ebf8283 2019-07-24 stsp if [ "$ret" != "0" ]; then
194 0ebf8283 2019-07-24 stsp diff -u $testroot/stdout.expected $testroot/stdout
195 0ebf8283 2019-07-24 stsp test_done "$testroot" "$ret"
199 0ebf8283 2019-07-24 stsp echo "modified alpha on master" > $testroot/content.expected
200 0ebf8283 2019-07-24 stsp cat $testroot/wt/alpha > $testroot/content
201 0ebf8283 2019-07-24 stsp cmp -s $testroot/content.expected $testroot/content
203 0ebf8283 2019-07-24 stsp if [ "$ret" != "0" ]; then
204 0ebf8283 2019-07-24 stsp diff -u $testroot/content.expected $testroot/content
205 0ebf8283 2019-07-24 stsp test_done "$testroot" "$ret"
209 0ebf8283 2019-07-24 stsp if [ -e $testroot/wt/beta ]; then
210 0ebf8283 2019-07-24 stsp echo "removed file beta still exists on disk" >&2
211 0ebf8283 2019-07-24 stsp test_done "$testroot" "1"
215 0ebf8283 2019-07-24 stsp echo "new file on master" > $testroot/content.expected
216 0ebf8283 2019-07-24 stsp cat $testroot/wt/epsilon/new > $testroot/content
217 0ebf8283 2019-07-24 stsp cmp -s $testroot/content.expected $testroot/content
219 0ebf8283 2019-07-24 stsp if [ "$ret" != "0" ]; then
220 0ebf8283 2019-07-24 stsp diff -u $testroot/content.expected $testroot/content
221 0ebf8283 2019-07-24 stsp test_done "$testroot" "$ret"
225 0ebf8283 2019-07-24 stsp (cd $testroot/wt && got status > $testroot/stdout)
227 0ebf8283 2019-07-24 stsp echo -n > $testroot/stdout.expected
228 0ebf8283 2019-07-24 stsp cmp -s $testroot/stdout.expected $testroot/stdout
230 0ebf8283 2019-07-24 stsp if [ "$ret" != "0" ]; then
231 0ebf8283 2019-07-24 stsp diff -u $testroot/stdout.expected $testroot/stdout
232 0ebf8283 2019-07-24 stsp test_done "$testroot" "$ret"
236 0ebf8283 2019-07-24 stsp (cd $testroot/wt && got log -l3 | grep ^commit > $testroot/stdout)
237 0ebf8283 2019-07-24 stsp echo "commit $new_commit1 (master)" > $testroot/stdout.expected
238 0ebf8283 2019-07-24 stsp echo "commit $new_commit2" >> $testroot/stdout.expected
239 0ebf8283 2019-07-24 stsp echo "commit $orig_commit" >> $testroot/stdout.expected
240 0ebf8283 2019-07-24 stsp cmp -s $testroot/stdout.expected $testroot/stdout
242 0ebf8283 2019-07-24 stsp if [ "$ret" != "0" ]; then
243 0ebf8283 2019-07-24 stsp diff -u $testroot/stdout.expected $testroot/stdout
244 86ac67ee 2019-07-25 stsp test_done "$testroot" "$ret"
248 86ac67ee 2019-07-25 stsp got diff -r $testroot/repo $orig_commit $new_commit1 \
249 86ac67ee 2019-07-25 stsp > $testroot/diff
250 86ac67ee 2019-07-25 stsp sed -i -e "s/$old_commit2/$new_commit1/" $testroot/diff.expected
251 86ac67ee 2019-07-25 stsp cmp -s $testroot/diff.expected $testroot/diff
253 86ac67ee 2019-07-25 stsp if [ "$ret" != "0" ]; then
254 86ac67ee 2019-07-25 stsp diff -u $testroot/diff.expected $testroot/diff
256 0ebf8283 2019-07-24 stsp test_done "$testroot" "$ret"
259 0ebf8283 2019-07-24 stsp function test_histedit_drop {
260 0ebf8283 2019-07-24 stsp local testroot=`test_init histedit_drop`
261 0ebf8283 2019-07-24 stsp local orig_commit=`git_show_head $testroot/repo`
263 0ebf8283 2019-07-24 stsp echo "modified alpha on master" > $testroot/repo/alpha
264 0ebf8283 2019-07-24 stsp (cd $testroot/repo && git rm -q beta)
265 0ebf8283 2019-07-24 stsp echo "new file on master" > $testroot/repo/epsilon/new
266 0ebf8283 2019-07-24 stsp (cd $testroot/repo && git add epsilon/new)
267 0ebf8283 2019-07-24 stsp git_commit $testroot/repo -m "committing changes"
268 0ebf8283 2019-07-24 stsp local old_commit1=`git_show_head $testroot/repo`
270 0ebf8283 2019-07-24 stsp echo "modified zeta on master" > $testroot/repo/epsilon/zeta
271 0ebf8283 2019-07-24 stsp git_commit $testroot/repo -m "committing to zeta on master"
272 0ebf8283 2019-07-24 stsp local old_commit2=`git_show_head $testroot/repo`
274 86ac67ee 2019-07-25 stsp got diff -r $testroot/repo $old_commit1 $old_commit2 \
275 86ac67ee 2019-07-25 stsp > $testroot/diff.expected
277 0ebf8283 2019-07-24 stsp got checkout -c $orig_commit $testroot/repo $testroot/wt > /dev/null
279 0ebf8283 2019-07-24 stsp if [ "$ret" != "0" ]; then
280 0ebf8283 2019-07-24 stsp test_done "$testroot" "$ret"
284 0ebf8283 2019-07-24 stsp echo "drop $old_commit1" > $testroot/histedit-script
285 0ebf8283 2019-07-24 stsp echo "pick $old_commit2" >> $testroot/histedit-script
287 0ebf8283 2019-07-24 stsp (cd $testroot/wt && got histedit -F $testroot/histedit-script \
288 0ebf8283 2019-07-24 stsp > $testroot/stdout)
290 0ebf8283 2019-07-24 stsp local new_commit2=`git_show_head $testroot/repo`
292 0ebf8283 2019-07-24 stsp local short_old_commit1=`trim_obj_id 28 $old_commit1`
293 0ebf8283 2019-07-24 stsp local short_old_commit2=`trim_obj_id 28 $old_commit2`
294 0ebf8283 2019-07-24 stsp local short_new_commit2=`trim_obj_id 28 $new_commit2`
296 0ebf8283 2019-07-24 stsp echo "$short_old_commit1 -> drop commit: committing changes" \
297 0ebf8283 2019-07-24 stsp > $testroot/stdout.expected
298 0ebf8283 2019-07-24 stsp echo "G epsilon/zeta" >> $testroot/stdout.expected
299 0ebf8283 2019-07-24 stsp echo -n "$short_old_commit2 -> $short_new_commit2: " \
300 0ebf8283 2019-07-24 stsp >> $testroot/stdout.expected
301 0ebf8283 2019-07-24 stsp echo "committing to zeta on master" >> $testroot/stdout.expected
302 0ebf8283 2019-07-24 stsp echo "Switching work tree to refs/heads/master" \
303 0ebf8283 2019-07-24 stsp >> $testroot/stdout.expected
305 0ebf8283 2019-07-24 stsp cmp -s $testroot/stdout.expected $testroot/stdout
307 0ebf8283 2019-07-24 stsp if [ "$ret" != "0" ]; then
308 0ebf8283 2019-07-24 stsp diff -u $testroot/stdout.expected $testroot/stdout
309 0ebf8283 2019-07-24 stsp test_done "$testroot" "$ret"
313 0ebf8283 2019-07-24 stsp for f in alpha beta; do
314 0ebf8283 2019-07-24 stsp echo "$f" > $testroot/content.expected
315 0ebf8283 2019-07-24 stsp cat $testroot/wt/$f > $testroot/content
316 0ebf8283 2019-07-24 stsp cmp -s $testroot/content.expected $testroot/content
318 0ebf8283 2019-07-24 stsp if [ "$ret" != "0" ]; then
319 0ebf8283 2019-07-24 stsp diff -u $testroot/content.expected $testroot/content
320 0ebf8283 2019-07-24 stsp test_done "$testroot" "$ret"
325 0ebf8283 2019-07-24 stsp if [ -e $testroot/wt/new ]; then
326 0ebf8283 2019-07-24 stsp echo "file new exists on disk but should not" >&2
327 0ebf8283 2019-07-24 stsp test_done "$testroot" "1"
331 0ebf8283 2019-07-24 stsp (cd $testroot/wt && got status > $testroot/stdout)
333 0ebf8283 2019-07-24 stsp echo -n > $testroot/stdout.expected
334 0ebf8283 2019-07-24 stsp cmp -s $testroot/stdout.expected $testroot/stdout
336 0ebf8283 2019-07-24 stsp if [ "$ret" != "0" ]; then
337 0ebf8283 2019-07-24 stsp diff -u $testroot/stdout.expected $testroot/stdout
338 0ebf8283 2019-07-24 stsp test_done "$testroot" "$ret"
342 0ebf8283 2019-07-24 stsp (cd $testroot/wt && got log -l3 | grep ^commit > $testroot/stdout)
343 0ebf8283 2019-07-24 stsp echo "commit $new_commit2 (master)" > $testroot/stdout.expected
344 0ebf8283 2019-07-24 stsp echo "commit $orig_commit" >> $testroot/stdout.expected
345 0ebf8283 2019-07-24 stsp cmp -s $testroot/stdout.expected $testroot/stdout
347 0ebf8283 2019-07-24 stsp if [ "$ret" != "0" ]; then
348 0ebf8283 2019-07-24 stsp diff -u $testroot/stdout.expected $testroot/stdout
349 86ac67ee 2019-07-25 stsp test_done "$testroot" "$ret"
353 86ac67ee 2019-07-25 stsp got diff -r $testroot/repo $orig_commit $new_commit2 \
354 86ac67ee 2019-07-25 stsp > $testroot/diff
355 86ac67ee 2019-07-25 stsp sed -i -e "s/$old_commit1/$orig_commit/" $testroot/diff.expected
356 86ac67ee 2019-07-25 stsp sed -i -e "s/$old_commit2/$new_commit2/" $testroot/diff.expected
357 86ac67ee 2019-07-25 stsp cmp -s $testroot/diff.expected $testroot/diff
359 86ac67ee 2019-07-25 stsp if [ "$ret" != "0" ]; then
360 86ac67ee 2019-07-25 stsp diff -u $testroot/diff.expected $testroot/diff
362 0ebf8283 2019-07-24 stsp test_done "$testroot" "$ret"
365 0ebf8283 2019-07-24 stsp function test_histedit_fold {
366 0ebf8283 2019-07-24 stsp local testroot=`test_init histedit_fold`
368 0ebf8283 2019-07-24 stsp local orig_commit=`git_show_head $testroot/repo`
370 0ebf8283 2019-07-24 stsp echo "modified alpha on master" > $testroot/repo/alpha
371 0ebf8283 2019-07-24 stsp (cd $testroot/repo && git rm -q beta)
372 0ebf8283 2019-07-24 stsp echo "new file on master" > $testroot/repo/epsilon/new
373 0ebf8283 2019-07-24 stsp (cd $testroot/repo && git add epsilon/new)
374 0ebf8283 2019-07-24 stsp git_commit $testroot/repo -m "committing changes"
375 0ebf8283 2019-07-24 stsp local old_commit1=`git_show_head $testroot/repo`
377 0ebf8283 2019-07-24 stsp echo "modified zeta on master" > $testroot/repo/epsilon/zeta
378 0ebf8283 2019-07-24 stsp git_commit $testroot/repo -m "committing to zeta on master"
379 0ebf8283 2019-07-24 stsp local old_commit2=`git_show_head $testroot/repo`
381 3f9de99f 2019-07-24 stsp echo "modified delta on master" > $testroot/repo/gamma/delta
382 3f9de99f 2019-07-24 stsp git_commit $testroot/repo -m "committing to delta on master"
383 3f9de99f 2019-07-24 stsp local old_commit3=`git_show_head $testroot/repo`
385 0ebf8283 2019-07-24 stsp got checkout -c $orig_commit $testroot/repo $testroot/wt > /dev/null
387 0ebf8283 2019-07-24 stsp if [ "$ret" != "0" ]; then
388 0ebf8283 2019-07-24 stsp test_done "$testroot" "$ret"
392 0ebf8283 2019-07-24 stsp echo "fold $old_commit1" > $testroot/histedit-script
393 3f9de99f 2019-07-24 stsp echo "drop $old_commit2" >> $testroot/histedit-script
394 3f9de99f 2019-07-24 stsp echo "pick $old_commit3" >> $testroot/histedit-script
395 0ebf8283 2019-07-24 stsp echo "mesg committing folded changes" >> $testroot/histedit-script
397 0ebf8283 2019-07-24 stsp (cd $testroot/wt && got histedit -F $testroot/histedit-script \
398 0ebf8283 2019-07-24 stsp > $testroot/stdout)
400 0ebf8283 2019-07-24 stsp local new_commit1=`git_show_parent_commit $testroot/repo`
401 0ebf8283 2019-07-24 stsp local new_commit2=`git_show_head $testroot/repo`
403 0ebf8283 2019-07-24 stsp local short_old_commit1=`trim_obj_id 28 $old_commit1`
404 0ebf8283 2019-07-24 stsp local short_old_commit2=`trim_obj_id 28 $old_commit2`
405 3f9de99f 2019-07-24 stsp local short_old_commit3=`trim_obj_id 28 $old_commit3`
406 0ebf8283 2019-07-24 stsp local short_new_commit1=`trim_obj_id 28 $new_commit1`
407 0ebf8283 2019-07-24 stsp local short_new_commit2=`trim_obj_id 28 $new_commit2`
409 0ebf8283 2019-07-24 stsp echo "G alpha" > $testroot/stdout.expected
410 0ebf8283 2019-07-24 stsp echo "D beta" >> $testroot/stdout.expected
411 0ebf8283 2019-07-24 stsp echo "A epsilon/new" >> $testroot/stdout.expected
412 0ebf8283 2019-07-24 stsp echo "$short_old_commit1 -> fold commit: committing changes" \
413 0ebf8283 2019-07-24 stsp >> $testroot/stdout.expected
414 3f9de99f 2019-07-24 stsp echo -n "$short_old_commit2 -> " >> $testroot/stdout.expected
415 3f9de99f 2019-07-24 stsp echo "drop commit: committing to zeta on master" \
416 0ebf8283 2019-07-24 stsp >> $testroot/stdout.expected
417 3f9de99f 2019-07-24 stsp echo "G gamma/delta" >> $testroot/stdout.expected
418 3f9de99f 2019-07-24 stsp echo -n "$short_old_commit3 -> $short_new_commit2: " \
419 3f9de99f 2019-07-24 stsp >> $testroot/stdout.expected
420 0ebf8283 2019-07-24 stsp echo "committing folded changes" >> $testroot/stdout.expected
421 0ebf8283 2019-07-24 stsp echo "Switching work tree to refs/heads/master" \
422 0ebf8283 2019-07-24 stsp >> $testroot/stdout.expected
424 0ebf8283 2019-07-24 stsp cmp -s $testroot/stdout.expected $testroot/stdout
426 0ebf8283 2019-07-24 stsp if [ "$ret" != "0" ]; then
427 0ebf8283 2019-07-24 stsp diff -u $testroot/stdout.expected $testroot/stdout
428 0ebf8283 2019-07-24 stsp test_done "$testroot" "$ret"
432 0ebf8283 2019-07-24 stsp echo "modified alpha on master" > $testroot/content.expected
433 0ebf8283 2019-07-24 stsp cat $testroot/wt/alpha > $testroot/content
434 0ebf8283 2019-07-24 stsp cmp -s $testroot/content.expected $testroot/content
436 0ebf8283 2019-07-24 stsp if [ "$ret" != "0" ]; then
437 0ebf8283 2019-07-24 stsp diff -u $testroot/content.expected $testroot/content
438 0ebf8283 2019-07-24 stsp test_done "$testroot" "$ret"
442 0ebf8283 2019-07-24 stsp if [ -e $testroot/wt/beta ]; then
443 0ebf8283 2019-07-24 stsp echo "removed file beta still exists on disk" >&2
444 0ebf8283 2019-07-24 stsp test_done "$testroot" "1"
448 0ebf8283 2019-07-24 stsp echo "new file on master" > $testroot/content.expected
449 0ebf8283 2019-07-24 stsp cat $testroot/wt/epsilon/new > $testroot/content
450 0ebf8283 2019-07-24 stsp cmp -s $testroot/content.expected $testroot/content
452 0ebf8283 2019-07-24 stsp if [ "$ret" != "0" ]; then
453 0ebf8283 2019-07-24 stsp diff -u $testroot/content.expected $testroot/content
454 0ebf8283 2019-07-24 stsp test_done "$testroot" "$ret"
458 0ebf8283 2019-07-24 stsp (cd $testroot/wt && got status > $testroot/stdout)
460 0ebf8283 2019-07-24 stsp echo -n > $testroot/stdout.expected
461 0ebf8283 2019-07-24 stsp cmp -s $testroot/stdout.expected $testroot/stdout
463 0ebf8283 2019-07-24 stsp if [ "$ret" != "0" ]; then
464 0ebf8283 2019-07-24 stsp diff -u $testroot/stdout.expected $testroot/stdout
465 0ebf8283 2019-07-24 stsp test_done "$testroot" "$ret"
469 0ebf8283 2019-07-24 stsp (cd $testroot/wt && got log -l3 | grep ^commit > $testroot/stdout)
470 0ebf8283 2019-07-24 stsp echo "commit $new_commit2 (master)" > $testroot/stdout.expected
471 0ebf8283 2019-07-24 stsp echo "commit $orig_commit" >> $testroot/stdout.expected
472 0ebf8283 2019-07-24 stsp cmp -s $testroot/stdout.expected $testroot/stdout
474 0ebf8283 2019-07-24 stsp if [ "$ret" != "0" ]; then
475 0ebf8283 2019-07-24 stsp diff -u $testroot/stdout.expected $testroot/stdout
477 0ebf8283 2019-07-24 stsp test_done "$testroot" "$ret"
480 0ebf8283 2019-07-24 stsp function test_histedit_edit {
481 0ebf8283 2019-07-24 stsp local testroot=`test_init histedit_edit`
483 0ebf8283 2019-07-24 stsp local orig_commit=`git_show_head $testroot/repo`
485 0ebf8283 2019-07-24 stsp echo "modified alpha on master" > $testroot/repo/alpha
486 0ebf8283 2019-07-24 stsp (cd $testroot/repo && git rm -q beta)
487 0ebf8283 2019-07-24 stsp echo "new file on master" > $testroot/repo/epsilon/new
488 0ebf8283 2019-07-24 stsp (cd $testroot/repo && git add epsilon/new)
489 0ebf8283 2019-07-24 stsp git_commit $testroot/repo -m "committing changes"
490 0ebf8283 2019-07-24 stsp local old_commit1=`git_show_head $testroot/repo`
492 0ebf8283 2019-07-24 stsp echo "modified zeta on master" > $testroot/repo/epsilon/zeta
493 0ebf8283 2019-07-24 stsp git_commit $testroot/repo -m "committing to zeta on master"
494 0ebf8283 2019-07-24 stsp local old_commit2=`git_show_head $testroot/repo`
496 0ebf8283 2019-07-24 stsp got checkout -c $orig_commit $testroot/repo $testroot/wt > /dev/null
498 0ebf8283 2019-07-24 stsp if [ "$ret" != "0" ]; then
499 0ebf8283 2019-07-24 stsp test_done "$testroot" "$ret"
503 0ebf8283 2019-07-24 stsp echo "edit $old_commit1" > $testroot/histedit-script
504 0ebf8283 2019-07-24 stsp echo "mesg committing changes" >> $testroot/histedit-script
505 0ebf8283 2019-07-24 stsp echo "pick $old_commit2" >> $testroot/histedit-script
507 0ebf8283 2019-07-24 stsp (cd $testroot/wt && got histedit -F $testroot/histedit-script \
508 0ebf8283 2019-07-24 stsp > $testroot/stdout)
510 0ebf8283 2019-07-24 stsp local short_old_commit1=`trim_obj_id 28 $old_commit1`
511 0ebf8283 2019-07-24 stsp local short_old_commit2=`trim_obj_id 28 $old_commit2`
513 0ebf8283 2019-07-24 stsp echo "G alpha" > $testroot/stdout.expected
514 0ebf8283 2019-07-24 stsp echo "D beta" >> $testroot/stdout.expected
515 0ebf8283 2019-07-24 stsp echo "A epsilon/new" >> $testroot/stdout.expected
516 0ebf8283 2019-07-24 stsp echo "Stopping histedit for amending commit $old_commit1" \
517 0ebf8283 2019-07-24 stsp >> $testroot/stdout.expected
518 0ebf8283 2019-07-24 stsp cmp -s $testroot/stdout.expected $testroot/stdout
520 0ebf8283 2019-07-24 stsp if [ "$ret" != "0" ]; then
521 0ebf8283 2019-07-24 stsp diff -u $testroot/stdout.expected $testroot/stdout
522 0ebf8283 2019-07-24 stsp test_done "$testroot" "$ret"
526 0ebf8283 2019-07-24 stsp echo "edited modified alpha on master" > $testroot/wt/alpha
528 f032f1f7 2019-08-04 stsp # test interaction of 'got stage' and histedit -c
529 f032f1f7 2019-08-04 stsp (cd $testroot/wt && got stage alpha > /dev/null)
530 f032f1f7 2019-08-04 stsp (cd $testroot/wt && got histedit -c > $testroot/stdout \
531 f032f1f7 2019-08-04 stsp 2> $testroot/stderr)
533 f032f1f7 2019-08-04 stsp if [ "$ret" == "0" ]; then
534 f032f1f7 2019-08-04 stsp echo "histedit succeeded unexpectedly" >&2
535 f032f1f7 2019-08-04 stsp test_done "$testroot" "1"
538 f032f1f7 2019-08-04 stsp echo -n "got: work tree contains files with staged changes; " \
539 f032f1f7 2019-08-04 stsp > $testroot/stderr.expected
540 f032f1f7 2019-08-04 stsp echo "these changes must be committed or unstaged first" \
541 f032f1f7 2019-08-04 stsp >> $testroot/stderr.expected
542 f032f1f7 2019-08-04 stsp cmp -s $testroot/stderr.expected $testroot/stderr
544 f032f1f7 2019-08-04 stsp if [ "$ret" != "0" ]; then
545 f032f1f7 2019-08-04 stsp diff -u $testroot/stderr.expected $testroot/stderr
546 f032f1f7 2019-08-04 stsp test_done "$testroot" "$ret"
550 f032f1f7 2019-08-04 stsp (cd $testroot/wt && got unstage alpha > /dev/null)
551 0ebf8283 2019-07-24 stsp (cd $testroot/wt && got histedit -c > $testroot/stdout)
553 0ebf8283 2019-07-24 stsp local new_commit1=`git_show_parent_commit $testroot/repo`
554 0ebf8283 2019-07-24 stsp local new_commit2=`git_show_head $testroot/repo`
556 0ebf8283 2019-07-24 stsp local short_new_commit1=`trim_obj_id 28 $new_commit1`
557 0ebf8283 2019-07-24 stsp local short_new_commit2=`trim_obj_id 28 $new_commit2`
559 0ebf8283 2019-07-24 stsp echo "$short_old_commit1 -> $short_new_commit1: committing changes" \
560 0ebf8283 2019-07-24 stsp > $testroot/stdout.expected
561 0ebf8283 2019-07-24 stsp echo "G epsilon/zeta" >> $testroot/stdout.expected
562 0ebf8283 2019-07-24 stsp echo -n "$short_old_commit2 -> $short_new_commit2: " \
563 0ebf8283 2019-07-24 stsp >> $testroot/stdout.expected
564 0ebf8283 2019-07-24 stsp echo "committing to zeta on master" >> $testroot/stdout.expected
565 0ebf8283 2019-07-24 stsp echo "Switching work tree to refs/heads/master" \
566 0ebf8283 2019-07-24 stsp >> $testroot/stdout.expected
568 0ebf8283 2019-07-24 stsp cmp -s $testroot/stdout.expected $testroot/stdout
570 0ebf8283 2019-07-24 stsp if [ "$ret" != "0" ]; then
571 0ebf8283 2019-07-24 stsp diff -u $testroot/stdout.expected $testroot/stdout
572 0ebf8283 2019-07-24 stsp test_done "$testroot" "$ret"
576 0ebf8283 2019-07-24 stsp echo "edited modified alpha on master" > $testroot/content.expected
577 0ebf8283 2019-07-24 stsp cat $testroot/wt/alpha > $testroot/content
578 0ebf8283 2019-07-24 stsp cmp -s $testroot/content.expected $testroot/content
580 0ebf8283 2019-07-24 stsp if [ "$ret" != "0" ]; then
581 0ebf8283 2019-07-24 stsp diff -u $testroot/content.expected $testroot/content
582 0ebf8283 2019-07-24 stsp test_done "$testroot" "$ret"
586 0ebf8283 2019-07-24 stsp if [ -e $testroot/wt/beta ]; then
587 0ebf8283 2019-07-24 stsp echo "removed file beta still exists on disk" >&2
588 0ebf8283 2019-07-24 stsp test_done "$testroot" "1"
592 0ebf8283 2019-07-24 stsp echo "new file on master" > $testroot/content.expected
593 0ebf8283 2019-07-24 stsp cat $testroot/wt/epsilon/new > $testroot/content
594 0ebf8283 2019-07-24 stsp cmp -s $testroot/content.expected $testroot/content
596 0ebf8283 2019-07-24 stsp if [ "$ret" != "0" ]; then
597 0ebf8283 2019-07-24 stsp diff -u $testroot/content.expected $testroot/content
598 0ebf8283 2019-07-24 stsp test_done "$testroot" "$ret"
602 0ebf8283 2019-07-24 stsp (cd $testroot/wt && got status > $testroot/stdout)
604 0ebf8283 2019-07-24 stsp echo -n > $testroot/stdout.expected
605 0ebf8283 2019-07-24 stsp cmp -s $testroot/stdout.expected $testroot/stdout
607 0ebf8283 2019-07-24 stsp if [ "$ret" != "0" ]; then
608 0ebf8283 2019-07-24 stsp diff -u $testroot/stdout.expected $testroot/stdout
609 0ebf8283 2019-07-24 stsp test_done "$testroot" "$ret"
613 0ebf8283 2019-07-24 stsp (cd $testroot/wt && got log -l3 | grep ^commit > $testroot/stdout)
614 0ebf8283 2019-07-24 stsp echo "commit $new_commit2 (master)" > $testroot/stdout.expected
615 0ebf8283 2019-07-24 stsp echo "commit $new_commit1" >> $testroot/stdout.expected
616 0ebf8283 2019-07-24 stsp echo "commit $orig_commit" >> $testroot/stdout.expected
617 0ebf8283 2019-07-24 stsp cmp -s $testroot/stdout.expected $testroot/stdout
619 0ebf8283 2019-07-24 stsp if [ "$ret" != "0" ]; then
620 0ebf8283 2019-07-24 stsp diff -u $testroot/stdout.expected $testroot/stdout
622 0ebf8283 2019-07-24 stsp test_done "$testroot" "$ret"
625 0ebf8283 2019-07-24 stsp function test_histedit_fold_last_commit {
626 0ebf8283 2019-07-24 stsp local testroot=`test_init histedit_fold_last_commit`
628 0ebf8283 2019-07-24 stsp local orig_commit=`git_show_head $testroot/repo`
630 0ebf8283 2019-07-24 stsp echo "modified alpha on master" > $testroot/repo/alpha
631 0ebf8283 2019-07-24 stsp (cd $testroot/repo && git rm -q beta)
632 0ebf8283 2019-07-24 stsp echo "new file on master" > $testroot/repo/epsilon/new
633 0ebf8283 2019-07-24 stsp (cd $testroot/repo && git add epsilon/new)
634 0ebf8283 2019-07-24 stsp git_commit $testroot/repo -m "committing changes"
635 0ebf8283 2019-07-24 stsp local old_commit1=`git_show_head $testroot/repo`
637 0ebf8283 2019-07-24 stsp echo "modified zeta on master" > $testroot/repo/epsilon/zeta
638 0ebf8283 2019-07-24 stsp git_commit $testroot/repo -m "committing to zeta on master"
639 0ebf8283 2019-07-24 stsp local old_commit2=`git_show_head $testroot/repo`
641 0ebf8283 2019-07-24 stsp got checkout -c $orig_commit $testroot/repo $testroot/wt > /dev/null
643 0ebf8283 2019-07-24 stsp if [ "$ret" != "0" ]; then
644 0ebf8283 2019-07-24 stsp test_done "$testroot" "$ret"
648 0ebf8283 2019-07-24 stsp echo "pick $old_commit1" > $testroot/histedit-script
649 0ebf8283 2019-07-24 stsp echo "fold $old_commit2" >> $testroot/histedit-script
650 0ebf8283 2019-07-24 stsp echo "mesg committing folded changes" >> $testroot/histedit-script
652 0ebf8283 2019-07-24 stsp (cd $testroot/wt && got histedit -F $testroot/histedit-script \
653 0ebf8283 2019-07-24 stsp > $testroot/stdout 2> $testroot/stderr)
656 0ebf8283 2019-07-24 stsp if [ "$ret" == "0" ]; then
657 0ebf8283 2019-07-24 stsp echo "histedit succeeded unexpectedly" >&2
658 0ebf8283 2019-07-24 stsp test_done "$testroot" "1"
662 0ebf8283 2019-07-24 stsp echo "got: last commit in histedit script cannot be folded" \
663 0ebf8283 2019-07-24 stsp > $testroot/stderr.expected
665 0ebf8283 2019-07-24 stsp cmp -s $testroot/stderr.expected $testroot/stderr
667 0ebf8283 2019-07-24 stsp if [ "$ret" != "0" ]; then
668 0ebf8283 2019-07-24 stsp diff -u $testroot/stderr.expected $testroot/stderr
670 0ebf8283 2019-07-24 stsp test_done "$testroot" "$ret"
673 0ebf8283 2019-07-24 stsp function test_histedit_missing_commit {
674 0ebf8283 2019-07-24 stsp local testroot=`test_init histedit_missing_commit`
676 0ebf8283 2019-07-24 stsp local orig_commit=`git_show_head $testroot/repo`
678 0ebf8283 2019-07-24 stsp echo "modified alpha on master" > $testroot/repo/alpha
679 0ebf8283 2019-07-24 stsp (cd $testroot/repo && git rm -q beta)
680 0ebf8283 2019-07-24 stsp echo "new file on master" > $testroot/repo/epsilon/new
681 0ebf8283 2019-07-24 stsp (cd $testroot/repo && git add epsilon/new)
682 0ebf8283 2019-07-24 stsp git_commit $testroot/repo -m "committing changes"
683 0ebf8283 2019-07-24 stsp local old_commit1=`git_show_head $testroot/repo`
685 0ebf8283 2019-07-24 stsp echo "modified zeta on master" > $testroot/repo/epsilon/zeta
686 0ebf8283 2019-07-24 stsp git_commit $testroot/repo -m "committing to zeta on master"
687 0ebf8283 2019-07-24 stsp local old_commit2=`git_show_head $testroot/repo`
689 0ebf8283 2019-07-24 stsp got checkout -c $orig_commit $testroot/repo $testroot/wt > /dev/null
691 0ebf8283 2019-07-24 stsp if [ "$ret" != "0" ]; then
692 0ebf8283 2019-07-24 stsp test_done "$testroot" "$ret"
696 0ebf8283 2019-07-24 stsp echo "pick $old_commit1" > $testroot/histedit-script
697 0ebf8283 2019-07-24 stsp echo "mesg committing changes" >> $testroot/histedit-script
699 0ebf8283 2019-07-24 stsp (cd $testroot/wt && got histedit -F $testroot/histedit-script \
700 0ebf8283 2019-07-24 stsp > $testroot/stdout 2> $testroot/stderr)
703 0ebf8283 2019-07-24 stsp if [ "$ret" == "0" ]; then
704 0ebf8283 2019-07-24 stsp echo "histedit succeeded unexpectedly" >&2
705 0ebf8283 2019-07-24 stsp test_done "$testroot" "1"
709 0ebf8283 2019-07-24 stsp echo "got: commit $old_commit2 missing from histedit script" \
710 0ebf8283 2019-07-24 stsp > $testroot/stderr.expected
712 0ebf8283 2019-07-24 stsp cmp -s $testroot/stderr.expected $testroot/stderr
714 0ebf8283 2019-07-24 stsp if [ "$ret" != "0" ]; then
715 0ebf8283 2019-07-24 stsp diff -u $testroot/stderr.expected $testroot/stderr
717 0ebf8283 2019-07-24 stsp test_done "$testroot" "$ret"
720 0ebf8283 2019-07-24 stsp function test_histedit_abort {
721 0ebf8283 2019-07-24 stsp local testroot=`test_init histedit_abort`
723 0ebf8283 2019-07-24 stsp local orig_commit=`git_show_head $testroot/repo`
725 0ebf8283 2019-07-24 stsp echo "modified alpha on master" > $testroot/repo/alpha
726 0ebf8283 2019-07-24 stsp (cd $testroot/repo && git rm -q beta)
727 0ebf8283 2019-07-24 stsp echo "new file on master" > $testroot/repo/epsilon/new
728 0ebf8283 2019-07-24 stsp (cd $testroot/repo && git add epsilon/new)
729 0ebf8283 2019-07-24 stsp git_commit $testroot/repo -m "committing changes"
730 0ebf8283 2019-07-24 stsp local old_commit1=`git_show_head $testroot/repo`
732 0ebf8283 2019-07-24 stsp echo "modified zeta on master" > $testroot/repo/epsilon/zeta
733 0ebf8283 2019-07-24 stsp git_commit $testroot/repo -m "committing to zeta on master"
734 0ebf8283 2019-07-24 stsp local old_commit2=`git_show_head $testroot/repo`
736 0ebf8283 2019-07-24 stsp got checkout -c $orig_commit $testroot/repo $testroot/wt > /dev/null
738 0ebf8283 2019-07-24 stsp if [ "$ret" != "0" ]; then
739 0ebf8283 2019-07-24 stsp test_done "$testroot" "$ret"
743 0ebf8283 2019-07-24 stsp echo "edit $old_commit1" > $testroot/histedit-script
744 0ebf8283 2019-07-24 stsp echo "mesg committing changes" >> $testroot/histedit-script
745 0ebf8283 2019-07-24 stsp echo "pick $old_commit2" >> $testroot/histedit-script
747 0ebf8283 2019-07-24 stsp (cd $testroot/wt && got histedit -F $testroot/histedit-script \
748 0ebf8283 2019-07-24 stsp > $testroot/stdout)
750 0ebf8283 2019-07-24 stsp local short_old_commit1=`trim_obj_id 28 $old_commit1`
751 0ebf8283 2019-07-24 stsp local short_old_commit2=`trim_obj_id 28 $old_commit2`
753 0ebf8283 2019-07-24 stsp echo "G alpha" > $testroot/stdout.expected
754 0ebf8283 2019-07-24 stsp echo "D beta" >> $testroot/stdout.expected
755 0ebf8283 2019-07-24 stsp echo "A epsilon/new" >> $testroot/stdout.expected
756 0ebf8283 2019-07-24 stsp echo "Stopping histedit for amending commit $old_commit1" \
757 0ebf8283 2019-07-24 stsp >> $testroot/stdout.expected
758 0ebf8283 2019-07-24 stsp cmp -s $testroot/stdout.expected $testroot/stdout
760 0ebf8283 2019-07-24 stsp if [ "$ret" != "0" ]; then
761 0ebf8283 2019-07-24 stsp diff -u $testroot/stdout.expected $testroot/stdout
762 0ebf8283 2019-07-24 stsp test_done "$testroot" "$ret"
766 0ebf8283 2019-07-24 stsp echo "edited modified alpha on master" > $testroot/wt/alpha
768 0ebf8283 2019-07-24 stsp (cd $testroot/wt && got histedit -a > $testroot/stdout)
770 0ebf8283 2019-07-24 stsp local new_commit1=`git_show_parent_commit $testroot/repo`
771 0ebf8283 2019-07-24 stsp local new_commit2=`git_show_head $testroot/repo`
773 0ebf8283 2019-07-24 stsp echo "Switching work tree to refs/heads/master" \
774 0ebf8283 2019-07-24 stsp > $testroot/stdout.expected
775 0ebf8283 2019-07-24 stsp echo "R alpha" >> $testroot/stdout.expected
776 0ebf8283 2019-07-24 stsp echo "R beta" >> $testroot/stdout.expected
777 0ebf8283 2019-07-24 stsp echo "R epsilon/new" >> $testroot/stdout.expected
778 0ebf8283 2019-07-24 stsp echo "Histedit of refs/heads/master aborted" \
779 0ebf8283 2019-07-24 stsp >> $testroot/stdout.expected
781 0ebf8283 2019-07-24 stsp cmp -s $testroot/stdout.expected $testroot/stdout
783 0ebf8283 2019-07-24 stsp if [ "$ret" != "0" ]; then
784 0ebf8283 2019-07-24 stsp diff -u $testroot/stdout.expected $testroot/stdout
785 0ebf8283 2019-07-24 stsp test_done "$testroot" "$ret"
789 0ebf8283 2019-07-24 stsp for f in alpha beta; do
790 0ebf8283 2019-07-24 stsp echo "$f" > $testroot/content.expected
791 0ebf8283 2019-07-24 stsp cat $testroot/wt/$f > $testroot/content
792 0ebf8283 2019-07-24 stsp cmp -s $testroot/content.expected $testroot/content
794 0ebf8283 2019-07-24 stsp if [ "$ret" != "0" ]; then
795 0ebf8283 2019-07-24 stsp diff -u $testroot/content.expected $testroot/content
796 0ebf8283 2019-07-24 stsp test_done "$testroot" "$ret"
801 0ebf8283 2019-07-24 stsp echo "new file on master" > $testroot/content.expected
802 0ebf8283 2019-07-24 stsp cat $testroot/wt/epsilon/new > $testroot/content
803 0ebf8283 2019-07-24 stsp cmp -s $testroot/content.expected $testroot/content
805 0ebf8283 2019-07-24 stsp if [ "$ret" != "0" ]; then
806 0ebf8283 2019-07-24 stsp diff -u $testroot/content.expected $testroot/content
807 0ebf8283 2019-07-24 stsp test_done "$testroot" "$ret"
811 0ebf8283 2019-07-24 stsp (cd $testroot/wt && got status > $testroot/stdout)
813 0ebf8283 2019-07-24 stsp echo "? epsilon/new" > $testroot/stdout.expected
814 0ebf8283 2019-07-24 stsp cmp -s $testroot/stdout.expected $testroot/stdout
816 0ebf8283 2019-07-24 stsp if [ "$ret" != "0" ]; then
817 0ebf8283 2019-07-24 stsp diff -u $testroot/stdout.expected $testroot/stdout
818 0ebf8283 2019-07-24 stsp test_done "$testroot" "$ret"
822 0ebf8283 2019-07-24 stsp (cd $testroot/wt && got log -l3 | grep ^commit > $testroot/stdout)
823 0ebf8283 2019-07-24 stsp echo "commit $new_commit2 (master)" > $testroot/stdout.expected
824 0ebf8283 2019-07-24 stsp echo "commit $new_commit1" >> $testroot/stdout.expected
825 0ebf8283 2019-07-24 stsp echo "commit $orig_commit" >> $testroot/stdout.expected
826 0160a755 2019-07-25 stsp cmp -s $testroot/stdout.expected $testroot/stdout
828 0160a755 2019-07-25 stsp if [ "$ret" != "0" ]; then
829 0160a755 2019-07-25 stsp diff -u $testroot/stdout.expected $testroot/stdout
831 0160a755 2019-07-25 stsp test_done "$testroot" "$ret"
834 a4027091 2019-07-25 stsp function test_histedit_path_prefix_drop {
835 a4027091 2019-07-25 stsp local testroot=`test_init histedit_path_prefix_drop`
836 0160a755 2019-07-25 stsp local orig_commit=`git_show_head $testroot/repo`
838 0160a755 2019-07-25 stsp echo "modified zeta" > $testroot/repo/epsilon/zeta
839 0160a755 2019-07-25 stsp git_commit $testroot/repo -m "changing zeta"
840 0160a755 2019-07-25 stsp local old_commit1=`git_show_head $testroot/repo`
842 0160a755 2019-07-25 stsp got checkout -c $orig_commit -p gamma $testroot/repo \
843 0160a755 2019-07-25 stsp $testroot/wt > /dev/null
845 0160a755 2019-07-25 stsp if [ "$ret" != "0" ]; then
846 0160a755 2019-07-25 stsp test_done "$testroot" "$ret"
850 0160a755 2019-07-25 stsp echo "drop $old_commit1" > $testroot/histedit-script
852 0160a755 2019-07-25 stsp (cd $testroot/wt && got histedit -F $testroot/histedit-script \
853 0160a755 2019-07-25 stsp > $testroot/stdout 2> $testroot/stderr)
856 0160a755 2019-07-25 stsp if [ "$ret" == "0" ]; then
857 0160a755 2019-07-25 stsp echo "histedit succeeded unexpectedly" >&2
858 0160a755 2019-07-25 stsp test_done "$testroot" "1"
862 0160a755 2019-07-25 stsp echo -n "got: cannot edit branch history which contains changes " \
863 0160a755 2019-07-25 stsp > $testroot/stderr.expected
864 0160a755 2019-07-25 stsp echo "outside of this work tree's path prefix" \
865 0160a755 2019-07-25 stsp >> $testroot/stderr.expected
867 0160a755 2019-07-25 stsp cmp -s $testroot/stderr.expected $testroot/stderr
869 0160a755 2019-07-25 stsp if [ "$ret" != "0" ]; then
870 0160a755 2019-07-25 stsp diff -u $testroot/stderr.expected $testroot/stderr
871 0160a755 2019-07-25 stsp test_done "$testroot" "$ret"
875 0160a755 2019-07-25 stsp rm -rf $testroot/wt
876 0160a755 2019-07-25 stsp got checkout -c $orig_commit -p epsilon $testroot/repo \
877 0160a755 2019-07-25 stsp $testroot/wt > /dev/null
879 0160a755 2019-07-25 stsp if [ "$ret" != "0" ]; then
880 0160a755 2019-07-25 stsp test_done "$testroot" "$ret"
883 0160a755 2019-07-25 stsp (cd $testroot/wt && got histedit -F $testroot/histedit-script \
884 0160a755 2019-07-25 stsp > $testroot/stdout)
886 0160a755 2019-07-25 stsp local short_old_commit1=`trim_obj_id 28 $old_commit1`
887 0160a755 2019-07-25 stsp local short_old_commit2=`trim_obj_id 28 $old_commit2`
889 0160a755 2019-07-25 stsp echo "$short_old_commit1 -> drop commit: changing zeta" \
890 0160a755 2019-07-25 stsp > $testroot/stdout.expected
891 0160a755 2019-07-25 stsp echo "Switching work tree to refs/heads/master" \
892 0160a755 2019-07-25 stsp >> $testroot/stdout.expected
894 0ebf8283 2019-07-24 stsp cmp -s $testroot/stdout.expected $testroot/stdout
896 0ebf8283 2019-07-24 stsp if [ "$ret" != "0" ]; then
897 0ebf8283 2019-07-24 stsp diff -u $testroot/stdout.expected $testroot/stdout
898 0160a755 2019-07-25 stsp test_done "$testroot" "$ret"
902 0160a755 2019-07-25 stsp echo "zeta" > $testroot/content.expected
903 0160a755 2019-07-25 stsp cat $testroot/wt/zeta > $testroot/content
904 0160a755 2019-07-25 stsp cmp -s $testroot/content.expected $testroot/content
906 0160a755 2019-07-25 stsp if [ "$ret" != "0" ]; then
907 0160a755 2019-07-25 stsp diff -u $testroot/content.expected $testroot/content
908 0160a755 2019-07-25 stsp test_done "$testroot" "$ret"
913 0160a755 2019-07-25 stsp (cd $testroot/wt && got status > $testroot/stdout)
915 0160a755 2019-07-25 stsp echo -n > $testroot/stdout.expected
916 0160a755 2019-07-25 stsp cmp -s $testroot/stdout.expected $testroot/stdout
918 0160a755 2019-07-25 stsp if [ "$ret" != "0" ]; then
919 0160a755 2019-07-25 stsp diff -u $testroot/stdout.expected $testroot/stdout
920 0160a755 2019-07-25 stsp test_done "$testroot" "$ret"
924 0160a755 2019-07-25 stsp (cd $testroot/wt && got log -l3 | grep ^commit > $testroot/stdout)
925 0160a755 2019-07-25 stsp echo "commit $orig_commit (master)" > $testroot/stdout.expected
926 b2c50a0a 2019-07-25 stsp cmp -s $testroot/stdout.expected $testroot/stdout
928 b2c50a0a 2019-07-25 stsp if [ "$ret" != "0" ]; then
929 b2c50a0a 2019-07-25 stsp diff -u $testroot/stdout.expected $testroot/stdout
931 b2c50a0a 2019-07-25 stsp test_done "$testroot" "$ret"
934 b2c50a0a 2019-07-25 stsp function test_histedit_path_prefix_edit {
935 b2c50a0a 2019-07-25 stsp local testroot=`test_init histedit_path_prefix_edit`
936 b2c50a0a 2019-07-25 stsp local orig_commit=`git_show_head $testroot/repo`
938 b2c50a0a 2019-07-25 stsp echo "modified zeta" > $testroot/repo/epsilon/zeta
939 b2c50a0a 2019-07-25 stsp git_commit $testroot/repo -m "changing zeta"
940 b2c50a0a 2019-07-25 stsp local old_commit1=`git_show_head $testroot/repo`
942 b2c50a0a 2019-07-25 stsp got diff -r $testroot/repo $orig_commit $old_commit1 \
943 b2c50a0a 2019-07-25 stsp > $testroot/diff.expected
945 b2c50a0a 2019-07-25 stsp got checkout -c $orig_commit -p gamma $testroot/repo \
946 b2c50a0a 2019-07-25 stsp $testroot/wt > /dev/null
948 b2c50a0a 2019-07-25 stsp if [ "$ret" != "0" ]; then
949 b2c50a0a 2019-07-25 stsp test_done "$testroot" "$ret"
953 b2c50a0a 2019-07-25 stsp echo "edit $old_commit1" > $testroot/histedit-script
954 b2c50a0a 2019-07-25 stsp echo "mesg modified zeta" >> $testroot/histedit-script
956 b2c50a0a 2019-07-25 stsp (cd $testroot/wt && got histedit -F $testroot/histedit-script \
957 b2c50a0a 2019-07-25 stsp > $testroot/stdout 2> $testroot/stderr)
960 b2c50a0a 2019-07-25 stsp if [ "$ret" == "0" ]; then
961 b2c50a0a 2019-07-25 stsp echo "histedit succeeded unexpectedly" >&2
962 b2c50a0a 2019-07-25 stsp test_done "$testroot" "1"
966 b2c50a0a 2019-07-25 stsp echo -n "got: cannot edit branch history which contains changes " \
967 b2c50a0a 2019-07-25 stsp > $testroot/stderr.expected
968 b2c50a0a 2019-07-25 stsp echo "outside of this work tree's path prefix" \
969 b2c50a0a 2019-07-25 stsp >> $testroot/stderr.expected
971 b2c50a0a 2019-07-25 stsp cmp -s $testroot/stderr.expected $testroot/stderr
973 b2c50a0a 2019-07-25 stsp if [ "$ret" != "0" ]; then
974 b2c50a0a 2019-07-25 stsp diff -u $testroot/stderr.expected $testroot/stderr
975 b2c50a0a 2019-07-25 stsp test_done "$testroot" "$ret"
979 b2c50a0a 2019-07-25 stsp rm -rf $testroot/wt
980 b2c50a0a 2019-07-25 stsp got checkout -c $orig_commit -p epsilon $testroot/repo \
981 b2c50a0a 2019-07-25 stsp $testroot/wt > /dev/null
983 b2c50a0a 2019-07-25 stsp if [ "$ret" != "0" ]; then
984 b2c50a0a 2019-07-25 stsp test_done "$testroot" "$ret"
987 b2c50a0a 2019-07-25 stsp (cd $testroot/wt && got histedit -F $testroot/histedit-script \
988 b2c50a0a 2019-07-25 stsp > $testroot/stdout)
990 b2c50a0a 2019-07-25 stsp local short_old_commit1=`trim_obj_id 28 $old_commit1`
992 b2c50a0a 2019-07-25 stsp echo "G zeta" > $testroot/stdout.expected
993 b2c50a0a 2019-07-25 stsp echo "Stopping histedit for amending commit $old_commit1" \
994 b2c50a0a 2019-07-25 stsp >> $testroot/stdout.expected
995 0160a755 2019-07-25 stsp cmp -s $testroot/stdout.expected $testroot/stdout
997 0160a755 2019-07-25 stsp if [ "$ret" != "0" ]; then
998 0160a755 2019-07-25 stsp diff -u $testroot/stdout.expected $testroot/stdout
999 b2c50a0a 2019-07-25 stsp test_done "$testroot" "$ret"
1003 b2c50a0a 2019-07-25 stsp echo "modified zeta" > $testroot/content.expected
1004 b2c50a0a 2019-07-25 stsp cat $testroot/wt/zeta > $testroot/content
1005 b2c50a0a 2019-07-25 stsp cmp -s $testroot/content.expected $testroot/content
1007 b2c50a0a 2019-07-25 stsp if [ "$ret" != "0" ]; then
1008 b2c50a0a 2019-07-25 stsp diff -u $testroot/content.expected $testroot/content
1009 b2c50a0a 2019-07-25 stsp test_done "$testroot" "$ret"
1013 b2c50a0a 2019-07-25 stsp (cd $testroot/wt && got status > $testroot/stdout)
1015 b2c50a0a 2019-07-25 stsp echo "M zeta"> $testroot/stdout.expected
1016 b2c50a0a 2019-07-25 stsp cmp -s $testroot/stdout.expected $testroot/stdout
1018 b2c50a0a 2019-07-25 stsp if [ "$ret" != "0" ]; then
1019 b2c50a0a 2019-07-25 stsp diff -u $testroot/stdout.expected $testroot/stdout
1020 b2c50a0a 2019-07-25 stsp test_done "$testroot" "$ret"
1024 b2c50a0a 2019-07-25 stsp (cd $testroot/wt && got histedit -c > $testroot/stdout)
1026 b2c50a0a 2019-07-25 stsp local new_commit1=`git_show_head $testroot/repo`
1027 b2c50a0a 2019-07-25 stsp local short_new_commit1=`trim_obj_id 28 $new_commit1`
1029 b2c50a0a 2019-07-25 stsp echo -n "$short_old_commit1 -> $short_new_commit1: " \
1030 b2c50a0a 2019-07-25 stsp > $testroot/stdout.expected
1031 b2c50a0a 2019-07-25 stsp echo "modified zeta" >> $testroot/stdout.expected
1032 b2c50a0a 2019-07-25 stsp echo "Switching work tree to refs/heads/master" \
1033 b2c50a0a 2019-07-25 stsp >> $testroot/stdout.expected
1035 b2c50a0a 2019-07-25 stsp cmp -s $testroot/stdout.expected $testroot/stdout
1037 b2c50a0a 2019-07-25 stsp if [ "$ret" != "0" ]; then
1038 b2c50a0a 2019-07-25 stsp diff -u $testroot/stdout.expected $testroot/stdout
1039 b2c50a0a 2019-07-25 stsp test_done "$testroot" "$ret"
1043 b2c50a0a 2019-07-25 stsp (cd $testroot/wt && got log -l3 | grep ^commit > $testroot/stdout)
1044 b2c50a0a 2019-07-25 stsp echo "commit $new_commit1 (master)" > $testroot/stdout.expected
1045 b2c50a0a 2019-07-25 stsp echo "commit $orig_commit" >> $testroot/stdout.expected
1046 b2c50a0a 2019-07-25 stsp cmp -s $testroot/stdout.expected $testroot/stdout
1048 b2c50a0a 2019-07-25 stsp if [ "$ret" != "0" ]; then
1049 b2c50a0a 2019-07-25 stsp diff -u $testroot/stdout.expected $testroot/stdout
1050 b2c50a0a 2019-07-25 stsp test_done "$testroot" "$ret"
1054 b2c50a0a 2019-07-25 stsp got diff -r $testroot/repo $orig_commit $new_commit1 \
1055 b2c50a0a 2019-07-25 stsp > $testroot/diff
1056 b2c50a0a 2019-07-25 stsp sed -i -e "s/$old_commit1/$new_commit1/" $testroot/diff.expected
1057 b2c50a0a 2019-07-25 stsp cmp -s $testroot/diff.expected $testroot/diff
1059 b2c50a0a 2019-07-25 stsp if [ "$ret" != "0" ]; then
1060 b2c50a0a 2019-07-25 stsp diff -u $testroot/diff.expected $testroot/diff
1062 0ebf8283 2019-07-24 stsp test_done "$testroot" "$ret"
1065 c7d20a3f 2019-07-30 stsp function test_histedit_outside_refs_heads {
1066 c7d20a3f 2019-07-30 stsp local testroot=`test_init histedit_outside_refs_heads`
1067 c7d20a3f 2019-07-30 stsp local commit1=`git_show_head $testroot/repo`
1069 c7d20a3f 2019-07-30 stsp got checkout $testroot/repo $testroot/wt > /dev/null
1071 c7d20a3f 2019-07-30 stsp if [ "$ret" != "0" ]; then
1072 c7d20a3f 2019-07-30 stsp echo "got checkout failed unexpectedly"
1073 c7d20a3f 2019-07-30 stsp test_done "$testroot" "$ret"
1077 c7d20a3f 2019-07-30 stsp echo "modified alpha" > $testroot/wt/alpha
1079 c7d20a3f 2019-07-30 stsp (cd $testroot/wt && got commit -m 'change alpha' \
1080 c7d20a3f 2019-07-30 stsp > $testroot/stdout 2> $testroot/stderr)
1082 c7d20a3f 2019-07-30 stsp if [ "$ret" != "0" ]; then
1083 c7d20a3f 2019-07-30 stsp echo "got commit failed unexpectedly" >&2
1084 c7d20a3f 2019-07-30 stsp test_done "$testroot" "1"
1087 c7d20a3f 2019-07-30 stsp local commit2=`git_show_head $testroot/repo`
1089 c7d20a3f 2019-07-30 stsp got ref -r $testroot/repo refs/remotes/origin/master master
1091 c7d20a3f 2019-07-30 stsp if [ "$ret" != "0" ]; then
1092 c7d20a3f 2019-07-30 stsp echo "got ref failed unexpectedly" >&2
1093 c7d20a3f 2019-07-30 stsp test_done "$testroot" "1"
1097 c7d20a3f 2019-07-30 stsp (cd $testroot/wt && got update -b origin/master -c $commit1 >/dev/null)
1099 c7d20a3f 2019-07-30 stsp if [ "$ret" != "0" ]; then
1100 c7d20a3f 2019-07-30 stsp echo "got update failed unexpectedly"
1101 c7d20a3f 2019-07-30 stsp test_done "$testroot" "$ret"
1105 c7d20a3f 2019-07-30 stsp echo "edit $commit2" > $testroot/histedit-script
1106 c7d20a3f 2019-07-30 stsp (cd $testroot/wt && got histedit -F $testroot/histedit-script \
1107 c7d20a3f 2019-07-30 stsp 2> $testroot/stderr)
1109 c7d20a3f 2019-07-30 stsp echo -n "got: will not edit commit history of a branch outside the " \
1110 c7d20a3f 2019-07-30 stsp > $testroot/stderr.expected
1111 c7d20a3f 2019-07-30 stsp echo '"refs/heads/" reference namespace' \
1112 c7d20a3f 2019-07-30 stsp >> $testroot/stderr.expected
1113 c7d20a3f 2019-07-30 stsp cmp -s $testroot/stderr.expected $testroot/stderr
1115 c7d20a3f 2019-07-30 stsp if [ "$ret" != "0" ]; then
1116 c7d20a3f 2019-07-30 stsp diff -u $testroot/stderr.expected $testroot/stderr
1118 0def28b1 2019-08-17 stsp test_done "$testroot" "$ret"
1121 0def28b1 2019-08-17 stsp function test_histedit_fold_last_commit_swap {
1122 0def28b1 2019-08-17 stsp local testroot=`test_init histedit_fold_last_commit_swap`
1124 0def28b1 2019-08-17 stsp local orig_commit=`git_show_head $testroot/repo`
1126 0def28b1 2019-08-17 stsp echo "modified alpha on master" > $testroot/repo/alpha
1127 0def28b1 2019-08-17 stsp (cd $testroot/repo && git rm -q beta)
1128 0def28b1 2019-08-17 stsp echo "new file on master" > $testroot/repo/epsilon/new
1129 0def28b1 2019-08-17 stsp (cd $testroot/repo && git add epsilon/new)
1130 0def28b1 2019-08-17 stsp git_commit $testroot/repo -m "committing changes"
1131 0def28b1 2019-08-17 stsp local old_commit1=`git_show_head $testroot/repo`
1133 0def28b1 2019-08-17 stsp echo "modified zeta on master" > $testroot/repo/epsilon/zeta
1134 0def28b1 2019-08-17 stsp git_commit $testroot/repo -m "committing to zeta on master"
1135 0def28b1 2019-08-17 stsp local old_commit2=`git_show_head $testroot/repo`
1137 0def28b1 2019-08-17 stsp got checkout -c $orig_commit $testroot/repo $testroot/wt > /dev/null
1139 0def28b1 2019-08-17 stsp if [ "$ret" != "0" ]; then
1140 0def28b1 2019-08-17 stsp test_done "$testroot" "$ret"
1144 0def28b1 2019-08-17 stsp # fold commit2 into commit1 (requires swapping commits)
1145 0def28b1 2019-08-17 stsp echo "fold $old_commit2" > $testroot/histedit-script
1146 0def28b1 2019-08-17 stsp echo "pick $old_commit1" >> $testroot/histedit-script
1147 0def28b1 2019-08-17 stsp echo "mesg committing folded changes" >> $testroot/histedit-script
1149 0def28b1 2019-08-17 stsp (cd $testroot/wt && got histedit -F $testroot/histedit-script \
1150 0def28b1 2019-08-17 stsp > $testroot/stdout 2> $testroot/stderr)
1153 0def28b1 2019-08-17 stsp if [ "$ret" != "0" ]; then
1154 0def28b1 2019-08-17 stsp echo "histedit failed unexpectedly" >&2
1155 0def28b1 2019-08-17 stsp test_done "$testroot" "$ret"
1159 0def28b1 2019-08-17 stsp local new_commit=`git_show_head $testroot/repo`
1161 0def28b1 2019-08-17 stsp local short_old_commit1=`trim_obj_id 28 $old_commit1`
1162 0def28b1 2019-08-17 stsp local short_old_commit2=`trim_obj_id 28 $old_commit2`
1163 0def28b1 2019-08-17 stsp local short_new_commit=`trim_obj_id 28 $new_commit`
1165 0def28b1 2019-08-17 stsp echo "G epsilon/zeta" >> $testroot/stdout.expected
1166 0def28b1 2019-08-17 stsp echo -n "$short_old_commit2 -> fold commit: committing to zeta " \
1167 0def28b1 2019-08-17 stsp >> $testroot/stdout.expected
1168 0def28b1 2019-08-17 stsp echo "on master" >> $testroot/stdout.expected
1169 0def28b1 2019-08-17 stsp echo "G alpha" >> $testroot/stdout.expected
1170 0def28b1 2019-08-17 stsp echo "D beta" >> $testroot/stdout.expected
1171 0def28b1 2019-08-17 stsp echo "A epsilon/new" >> $testroot/stdout.expected
1172 0def28b1 2019-08-17 stsp echo -n "$short_old_commit1 -> $short_new_commit: " \
1173 0def28b1 2019-08-17 stsp >> $testroot/stdout.expected
1174 0def28b1 2019-08-17 stsp echo "committing folded changes" >> $testroot/stdout.expected
1175 0def28b1 2019-08-17 stsp echo "Switching work tree to refs/heads/master" \
1176 0def28b1 2019-08-17 stsp >> $testroot/stdout.expected
1178 0def28b1 2019-08-17 stsp cmp -s $testroot/stdout.expected $testroot/stdout
1180 0def28b1 2019-08-17 stsp if [ "$ret" != "0" ]; then
1181 0def28b1 2019-08-17 stsp diff -u $testroot/stdout.expected $testroot/stdout
1183 c7d20a3f 2019-07-30 stsp test_done "$testroot" "$ret"
1186 0ebf8283 2019-07-24 stsp run_test test_histedit_no_op
1187 0ebf8283 2019-07-24 stsp run_test test_histedit_swap
1188 0ebf8283 2019-07-24 stsp run_test test_histedit_drop
1189 0ebf8283 2019-07-24 stsp run_test test_histedit_fold
1190 0ebf8283 2019-07-24 stsp run_test test_histedit_edit
1191 0ebf8283 2019-07-24 stsp run_test test_histedit_fold_last_commit
1192 0ebf8283 2019-07-24 stsp run_test test_histedit_missing_commit
1193 0ebf8283 2019-07-24 stsp run_test test_histedit_abort
1194 a4027091 2019-07-25 stsp run_test test_histedit_path_prefix_drop
1195 b2c50a0a 2019-07-25 stsp run_test test_histedit_path_prefix_edit
1196 c7d20a3f 2019-07-30 stsp run_test test_histedit_outside_refs_heads
1197 0def28b1 2019-08-17 stsp run_test test_histedit_fold_last_commit_swap