Comments
Patch
@@ -1,22 +1,28 @@
+Test histedit extention: Fold commands
+======================================
+
+This test file is dedicated to testing the fold command in non conflicting
+case.
+
+Initialization
+---------------
+
+
$ . "$TESTDIR/histedit-helpers.sh"
$ cat >> $HGRCPATH <<EOF
> [ui]
> logtemplate = {rev}:{node|short} {desc|firstline}'\n
> [extensions]
> graphlog=
> histedit=
> EOF
- $ EDITED="$TESTTMP/editedhistory"
- $ cat > $EDITED <<EOF
- > pick e860deea161a e
- > pick 652413bf663e f
- > fold 177f92b77385 c
- > pick 055a42cdd887 d
- > EOF
+
+Simple folding
+--------------------
$ initrepo ()
> {
> hg init r
> cd r
> for x in a b c d e f ; do
@@ -26,11 +32,12 @@
> done
> }
$ initrepo
-log before edit
+Initial log
+
$ hg log --graph
@ 5:652413bf663e f'
|
o 4:e860deea161a e'
|
@@ -41,11 +48,17 @@ log before edit
o 1:d2ae7f538514 b'
|
o 0:cb9a9f314b8b a'
-edit the history
+ $ EDITED="$TESTTMP/editedhistory"
+ $ cat > $EDITED <<EOF
+ > pick e860deea161a e
+ > pick 652413bf663e f
+ > fold 177f92b77385 c
+ > pick 055a42cdd887 d
+ > EOF
$ HGEDITOR="cat \"$EDITED\" > " hg histedit 177f92b77385 2>&1 | fixbundle
0 files updated, 0 files merged, 4 files removed, 0 files unresolved
0 files updated, 0 files merged, 0 files removed, 0 files unresolved
0 files updated, 0 files merged, 0 files removed, 0 files unresolved
0 files updated, 0 files merged, 2 files removed, 0 files unresolved
@@ -82,10 +95,14 @@ check histedit_source
3:5e24935bad3d pick e860deea161a e'
$ cd ..
folding and creating no new change doesn't break:
+-------------------------------------------------
+
+folded content is dropped during a merge.
+
$ mkdir fold-to-empty-test
$ cd fold-to-empty-test
$ hg init
$ printf "1\n2\n3\n" > file
$ hg add file
@@ -141,10 +158,15 @@ should effectively drop the changes from
o 0:0189ba417d34 1+2+3'
$ cd ..
+
+Test fold through dropped
+-------------------------
+
+
Test corner case where folded revision is separated from its parent by a
dropped revision.
$ hg init fold-with-dropped