Mercurial > hg
diff tests/test-log.out @ 11562:efbc09fdefd8 stable
test-log: Add test for "hg log -pf" (issue647)
To test f786fc4b8764 we analyze this repo:
0 | 1 | 2 | 3 | 4
a ------------> b
\
b -> dir/b -------> e
d
We follow dir/b and expects rev 0, 1 and 2.
A log following b will surprisingly report rev 0 and 1. That's because the
content and the parents are the same in rev 1 and rev 3, and the revlog entry
from rev 1 is thus reused in rev 3 even though the revlink is incorrect.
Note that if we follow e then we will get all revs, including rev 3, because b
gets added to the set of interesting filenames we are following through all
revisions. That might be surprising, but that's (currently) how it is.
Original test case by Joel Rosdahl <joel@rosdahl.net>
Original test reviewed by Nicolas Dumazet <nicdumz@gmail.com>
author | Joel Rosdahl <joel@rosdahl.net> |
---|---|
date | Thu, 08 Jul 2010 22:44:15 +0200 |
parents | 2eaaad99f2f0 |
children | dbb98d8fbcaf 28ddf67198b2 |
line wrap: on
line diff
--- a/tests/test-log.out Wed Jul 14 11:02:20 2010 -0400 +++ b/tests/test-log.out Thu Jul 08 22:44:15 2010 +0200 @@ -76,6 +76,65 @@ a +% log -pf dir/b +changeset: 2:41dd4284081e +user: test +date: Thu Jan 01 00:00:03 1970 +0000 +summary: c + +diff -r 784de7cef101 -r 41dd4284081e dir/b +--- /dev/null Thu Jan 01 00:00:00 1970 +0000 ++++ b/dir/b Thu Jan 01 00:00:03 1970 +0000 +@@ -0,0 +1,1 @@ ++a + +changeset: 1:784de7cef101 +user: test +date: Thu Jan 01 00:00:02 1970 +0000 +summary: b + +diff -r 8580ff50825a -r 784de7cef101 b +--- /dev/null Thu Jan 01 00:00:00 1970 +0000 ++++ b/b Thu Jan 01 00:00:02 1970 +0000 +@@ -0,0 +1,1 @@ ++a + +changeset: 0:8580ff50825a +user: test +date: Thu Jan 01 00:00:01 1970 +0000 +summary: a + +diff -r 000000000000 -r 8580ff50825a a +--- /dev/null Thu Jan 01 00:00:00 1970 +0000 ++++ b/a Thu Jan 01 00:00:01 1970 +0000 +@@ -0,0 +1,1 @@ ++a + +% log -vf dir/b +changeset: 2:41dd4284081e +user: test +date: Thu Jan 01 00:00:03 1970 +0000 +files: b dir/b +description: +c + + +changeset: 1:784de7cef101 +user: test +date: Thu Jan 01 00:00:02 1970 +0000 +files: b +description: +b + + +changeset: 0:8580ff50825a +user: test +date: Thu Jan 01 00:00:01 1970 +0000 +files: a +description: +a + + % log copies with --copies 4 e (dir/b) 3 b (a)