Commit 291ce4af authored by Anton Shestakov's avatar Anton Shestakov
Browse files

tests: add test-amend-merge.t with a simple merge amended by various commands

--HG--
branch : stable
parent 94aed9c7ce69
This test amends a merge commit using various commands, including topics
$ . $TESTDIR/testlib/common.sh
$ cat >> $HGRCPATH << EOF
> [extensions]
> evolve =
> topic =
> EOF
$ hg init amending-a-merge
$ cd amending-a-merge
$ mkcommit root
$ mkcommit apple
$ hg up 'desc("root")'
0 files updated, 0 files merged, 1 files removed, 0 files unresolved
$ mkcommit banana
created new head
(consider using topic for lightweight branches. See 'hg help topic')
$ hg up 'desc("apple")'
1 files updated, 0 files merged, 1 files removed, 0 files unresolved
$ hg merge 'desc("banana")'
1 files updated, 0 files merged, 0 files removed, 0 files unresolved
(branch merge, don't forget to commit)
$ hg ci -m merge
$ hg diff -r 'p1(.)' -r '.'
diff -r 88a060ab6523 -r c20705a6a8c4 banana
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/banana Thu Jan 01 00:00:00 1970 +0000
@@ -0,0 +1,1 @@
+banana
$ hg diff -r 'p2(.)' -r '.'
diff -r d8c7baf0ca58 -r c20705a6a8c4 apple
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/apple Thu Jan 01 00:00:00 1970 +0000
@@ -0,0 +1,1 @@
+apple
amend
$ hg amend -m 'merge, amend'
$ hg diff -r 'p1(.)' -r '.'
diff -r 88a060ab6523 -r 456753fae3cd banana
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/banana Thu Jan 01 00:00:00 1970 +0000
@@ -0,0 +1,1 @@
+banana
$ hg diff -r 'p2(.)' -r '.'
diff -r d8c7baf0ca58 -r 456753fae3cd apple
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/apple Thu Jan 01 00:00:00 1970 +0000
@@ -0,0 +1,1 @@
+apple
metaedit
$ hg metaedit -m 'merge, metaedit'
0 files updated, 0 files merged, 0 files removed, 0 files unresolved
$ hg diff -r 'p1(.)' -r '.'
diff -r 88a060ab6523 -r 1528d42f3e83 banana
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/banana Thu Jan 01 00:00:00 1970 +0000
@@ -0,0 +1,1 @@
+banana
$ hg diff -r 'p2(.)' -r '.'
diff -r d8c7baf0ca58 -r 1528d42f3e83 apple
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/apple Thu Jan 01 00:00:00 1970 +0000
@@ -0,0 +1,1 @@
+apple
......@@ -35,7 +35,7 @@ Archiving to a separate location to avoid hardlink mess when the repo is shared
$ tar -tzf hg-evolve-*.tar.gz | sed 's|^hg-evolve-[^/]*/||' | sort > files
$ wc -l files
349 files
350 files
$ fgrep debian files
tests/test-check-debian.t
$ fgrep __init__.py files
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment