test-copies: add 3 new files with their own content
authorPierre-Yves David <pierre-yves.david@octobus.net>
Fri, 19 Feb 2021 17:06:12 +0100
changeset 46555 46205a478a08
parent 46554 664bee002d1a
child 46556 0ebfd02dafd5
test-copies: add 3 new files with their own content The new `p`, `q` and `r` file mirror the `a`, `b` and `h` but with different content for each files. This will be used to create "mirror" test case that involve actual merge happening. For now, we only add the file to keep patches small and easier to review. Differential Revision: https://phab.mercurial-scm.org/D10053
tests/test-copies-chain-merge.t
--- a/tests/test-copies-chain-merge.t	Fri Feb 19 16:37:55 2021 +0100
+++ b/tests/test-copies-chain-merge.t	Fri Feb 19 17:06:12 2021 +0100
@@ -75,10 +75,16 @@
   $ cp ../same-content.txt a
   $ cp ../same-content.txt b
   $ cp ../same-content.txt h
+  $ echo "original content for P" > p
+  $ echo "original content for Q" > q
+  $ echo "original content for R" > r
   $ hg ci -Am 'i-0 initial commit: a b h'
   adding a
   adding b
   adding h
+  adding p
+  adding q
+  adding r
   $ hg mv a c
   $ hg ci -Am 'i-1: a -move-> c'
   $ hg mv c d
@@ -652,7 +658,7 @@
   $ case_desc="simple merge - C side: d is the results of renames then deleted, H side: d is result of another rename (same content as the other branch)"
 
   $ hg up 'desc("i-0")'
-  3 files updated, 0 files merged, 0 files removed, 0 files unresolved
+  6 files updated, 0 files merged, 0 files removed, 0 files unresolved
   $ hg mv b d
   $ hg ci -m "h-1: b -(move)-> d"
   created new head
@@ -1228,6 +1234,9 @@
   added      : a, ;
   added      : b, ;
   added      : h, ;
+  added      : p, ;
+  added      : q, ;
+  added      : r, ;
 
   $ for rev in `hg log --rev 'all()' -T '{rev}\n'`; do
   >     case_id=`hg log -r $rev -T '{word(0, desc, ":")}\n'`
@@ -1237,11 +1246,14 @@
   > done
   ##### revision "i-0 initial commit" #####
   1 sidedata entries
-   entry-0014 size 34
-    '\x00\x00\x00\x03\x04\x00\x00\x00\x01\x00\x00\x00\x00\x04\x00\x00\x00\x02\x00\x00\x00\x00\x04\x00\x00\x00\x03\x00\x00\x00\x00abh'
+   entry-0014 size 64
+    '\x00\x00\x00\x06\x04\x00\x00\x00\x01\x00\x00\x00\x00\x04\x00\x00\x00\x02\x00\x00\x00\x00\x04\x00\x00\x00\x03\x00\x00\x00\x00\x04\x00\x00\x00\x04\x00\x00\x00\x00\x04\x00\x00\x00\x05\x00\x00\x00\x00\x04\x00\x00\x00\x06\x00\x00\x00\x00abhpqr'
   added      : a, ;
   added      : b, ;
   added      : h, ;
+  added      : p, ;
+  added      : q, ;
+  added      : r, ;
   ##### revision "i-1" #####
   1 sidedata entries
    entry-0014 size 24