annotate tests/test-strip-cross.t @ 12607:1393a81b3bdc

merge with stable
author Martin Geisler <mg@aragost.com>
date Fri, 01 Oct 2010 16:43:03 +0200
parents 5df8ef0f3f51
children 6cc4b14fb76b
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
12492
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
1 test stripping of filelogs where the linkrev doesn't always increase
5909
f45f7390c1c5 strip: calculate list of extra nodes to save and pass it to changegroupsubset
Alexis S. L. Carvalho <alexis@cecm.usp.br>
parents:
diff changeset
2
12492
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
3 $ . $TESTDIR/helpers.sh
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
4 $ echo '[extensions]' >> $HGRCPATH
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
5 $ echo 'hgext.mq =' >> $HGRCPATH
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
6 $ hg init orig
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
7 $ cd orig
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
8 $ commit()
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
9 > {
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
10 > hg up -qC null
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
11 > count=1
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
12 > for i in "$@"; do
12537
5df8ef0f3f51 tests: fix tabs/indentation in test-strip-cross.t
Adrian Buehlmann <adrian@cadifra.com>
parents: 12492
diff changeset
13 > for f in $i; do
5df8ef0f3f51 tests: fix tabs/indentation in test-strip-cross.t
Adrian Buehlmann <adrian@cadifra.com>
parents: 12492
diff changeset
14 > echo $count > $f
5df8ef0f3f51 tests: fix tabs/indentation in test-strip-cross.t
Adrian Buehlmann <adrian@cadifra.com>
parents: 12492
diff changeset
15 > done
5df8ef0f3f51 tests: fix tabs/indentation in test-strip-cross.t
Adrian Buehlmann <adrian@cadifra.com>
parents: 12492
diff changeset
16 > count=`expr $count + 1`
12492
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
17 > done
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
18 > hg commit -qAm "$*"
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
19 > }
5909
f45f7390c1c5 strip: calculate list of extra nodes to save and pass it to changegroupsubset
Alexis S. L. Carvalho <alexis@cecm.usp.br>
parents:
diff changeset
20
12492
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
21 2 1 0 2 0 1 2
5909
f45f7390c1c5 strip: calculate list of extra nodes to save and pass it to changegroupsubset
Alexis S. L. Carvalho <alexis@cecm.usp.br>
parents:
diff changeset
22
12492
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
23 $ commit '201 210'
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
24 $ commit '102 120' '210'
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
25 $ commit '021'
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
26 $ commit '201' '021 120'
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
27 $ commit '012 021' '102 201' '120 210'
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
28 $ commit 'manifest-file'
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
29 $ commit '102 120' '012 210' '021 201'
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
30 $ commit '201 210' '021 120' '012 102'
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
31 $ HGUSER=another-user; export HGUSER
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
32 $ commit 'manifest-file'
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
33 $ commit '012' 'manifest-file'
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
34 $ cd ..
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
35 $ hg clone -q -U -r -1 -r -2 -r -3 -r -4 -r -6 orig crossed
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
36 $ for i in crossed/.hg/store/00manifest.i crossed/.hg/store/data/*.i; do
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
37 > echo $i
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
38 > hg debugindex $i
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
39 > echo
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
40 > done
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
41 crossed/.hg/store/00manifest.i
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
42 rev offset length base linkrev nodeid p1 p2
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
43 0 0 112 0 0 6f105cbb914d 000000000000 000000000000
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
44 1 112 56 1 3 1b55917b3699 000000000000 000000000000
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
45 2 168 123 1 1 8f3d04e263e5 000000000000 000000000000
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
46 3 291 122 1 2 f0ef8726ac4f 000000000000 000000000000
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
47 4 413 87 4 4 0b76e38b4070 000000000000 000000000000
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
48
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
49 crossed/.hg/store/data/012.i
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
50 rev offset length base linkrev nodeid p1 p2
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
51 0 0 3 0 0 b8e02f643373 000000000000 000000000000
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
52 1 3 3 1 1 5d9299349fc0 000000000000 000000000000
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
53 2 6 3 2 2 2661d26c6496 000000000000 000000000000
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
54
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
55 crossed/.hg/store/data/021.i
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
56 rev offset length base linkrev nodeid p1 p2
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
57 0 0 3 0 0 b8e02f643373 000000000000 000000000000
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
58 1 3 3 1 2 5d9299349fc0 000000000000 000000000000
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
59 2 6 3 2 1 2661d26c6496 000000000000 000000000000
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
60
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
61 crossed/.hg/store/data/102.i
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
62 rev offset length base linkrev nodeid p1 p2
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
63 0 0 3 0 1 b8e02f643373 000000000000 000000000000
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
64 1 3 3 1 0 5d9299349fc0 000000000000 000000000000
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
65 2 6 3 2 2 2661d26c6496 000000000000 000000000000
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
66
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
67 crossed/.hg/store/data/120.i
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
68 rev offset length base linkrev nodeid p1 p2
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
69 0 0 3 0 1 b8e02f643373 000000000000 000000000000
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
70 1 3 3 1 2 5d9299349fc0 000000000000 000000000000
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
71 2 6 3 2 0 2661d26c6496 000000000000 000000000000
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
72
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
73 crossed/.hg/store/data/201.i
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
74 rev offset length base linkrev nodeid p1 p2
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
75 0 0 3 0 2 b8e02f643373 000000000000 000000000000
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
76 1 3 3 1 0 5d9299349fc0 000000000000 000000000000
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
77 2 6 3 2 1 2661d26c6496 000000000000 000000000000
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
78
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
79 crossed/.hg/store/data/210.i
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
80 rev offset length base linkrev nodeid p1 p2
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
81 0 0 3 0 2 b8e02f643373 000000000000 000000000000
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
82 1 3 3 1 1 5d9299349fc0 000000000000 000000000000
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
83 2 6 3 2 0 2661d26c6496 000000000000 000000000000
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
84
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
85 crossed/.hg/store/data/manifest-file.i
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
86 rev offset length base linkrev nodeid p1 p2
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
87 0 0 3 0 3 b8e02f643373 000000000000 000000000000
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
88 1 3 3 1 4 5d9299349fc0 000000000000 000000000000
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
89
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
90 $ for i in 0 1 2 3 4; do
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
91 > hg clone -q -U --pull crossed $i
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
92 > echo "% Trying to strip revision $i"
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
93 > hg --cwd $i strip $i | hidebackup
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
94 > echo "% Verifying"
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
95 > hg --cwd $i verify
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
96 > echo
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
97 > done
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
98 % Trying to strip revision 0
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
99 saved backup bundle to
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
100 % Verifying
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
101 checking changesets
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
102 checking manifests
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
103 crosschecking files in changesets and manifests
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
104 checking files
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
105 7 files, 4 changesets, 15 total revisions
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
106
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
107 % Trying to strip revision 1
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
108 saved backup bundle to
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
109 % Verifying
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
110 checking changesets
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
111 checking manifests
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
112 crosschecking files in changesets and manifests
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
113 checking files
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
114 7 files, 4 changesets, 14 total revisions
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
115
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
116 % Trying to strip revision 2
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
117 saved backup bundle to
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
118 % Verifying
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
119 checking changesets
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
120 checking manifests
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
121 crosschecking files in changesets and manifests
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
122 checking files
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
123 7 files, 4 changesets, 14 total revisions
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
124
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
125 % Trying to strip revision 3
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
126 saved backup bundle to
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
127 % Verifying
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
128 checking changesets
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
129 checking manifests
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
130 crosschecking files in changesets and manifests
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
131 checking files
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
132 7 files, 4 changesets, 19 total revisions
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
133
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
134 % Trying to strip revision 4
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
135 saved backup bundle to
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
136 % Verifying
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
137 checking changesets
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
138 checking manifests
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
139 crosschecking files in changesets and manifests
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
140 checking files
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
141 7 files, 4 changesets, 19 total revisions
72be1ab55d62 tests: unify test-strip-cross
Matt Mackall <mpm@selenic.com>
parents: 11208
diff changeset
142