comparison tests/test-init.t @ 26921:b11495c2a7e2

tests: test generaldelta configuration in test-init.t We turn the feature on for the whole test and test that it can properly be disabled through the config.
author Pierre-Yves David <pierre-yves.david@fb.com>
date Mon, 19 Oct 2015 15:25:58 +0200
parents c63bf97cf7c7
children fe0667cc521e
comparison
equal deleted inserted replaced
26920:4d1a96bb831f 26921:b11495c2a7e2
1 This test tries to exercise the ssh functionality with a dummy script 1 This test tries to exercise the ssh functionality with a dummy script
2
3 (enable general delta early)
4
5 $ cat << EOF >> $HGRCPATH
6 > [format]
7 > usegeneraldelta=yes
8 > EOF
2 9
3 $ checknewrepo() 10 $ checknewrepo()
4 > { 11 > {
5 > name=$1 12 > name=$1
6 > if [ -d "$name"/.hg/store ]; then 13 > if [ -d "$name"/.hg/store ]; then
18 $ checknewrepo local 25 $ checknewrepo local
19 store created 26 store created
20 00changelog.i created 27 00changelog.i created
21 dotencode 28 dotencode
22 fncache 29 fncache
30 generaldelta
23 revlogv1 31 revlogv1
24 store 32 store
25 $ echo this > local/foo 33 $ echo this > local/foo
26 $ hg ci --cwd local -A -m "init" 34 $ hg ci --cwd local -A -m "init"
27 adding foo 35 adding foo
53 61
54 creating repo with format.usestore=false 62 creating repo with format.usestore=false
55 63
56 $ hg --config format.usestore=false init old 64 $ hg --config format.usestore=false init old
57 $ checknewrepo old 65 $ checknewrepo old
66 generaldelta
58 revlogv1 67 revlogv1
59 68
60 creating repo with format.usefncache=false 69 creating repo with format.usefncache=false
61 70
62 $ hg --config format.usefncache=false init old2 71 $ hg --config format.usefncache=false init old2
63 $ checknewrepo old2 72 $ checknewrepo old2
64 store created 73 store created
65 00changelog.i created 74 00changelog.i created
75 generaldelta
66 revlogv1 76 revlogv1
67 store 77 store
68 78
69 creating repo with format.dotencode=false 79 creating repo with format.dotencode=false
70 80
71 $ hg --config format.dotencode=false init old3 81 $ hg --config format.dotencode=false init old3
72 $ checknewrepo old3 82 $ checknewrepo old3
73 store created 83 store created
74 00changelog.i created 84 00changelog.i created
85 fncache
86 generaldelta
87 revlogv1
88 store
89
90 creating repo with format.dotencode=false
91
92 $ hg --config format.generaldelta=false --config format.usegeneraldelta=false init old4
93 $ checknewrepo old4
94 store created
95 00changelog.i created
96 dotencode
75 fncache 97 fncache
76 revlogv1 98 revlogv1
77 store 99 store
78 100
79 test failure 101 test failure
184 $ checknewrepo local/sub/repo 206 $ checknewrepo local/sub/repo
185 store created 207 store created
186 00changelog.i created 208 00changelog.i created
187 dotencode 209 dotencode
188 fncache 210 fncache
211 generaldelta
189 revlogv1 212 revlogv1
190 store 213 store
191 214
192 prepare test of init of url configured from paths 215 prepare test of init of url configured from paths
193 216
201 $ checknewrepo "url from paths" 224 $ checknewrepo "url from paths"
202 store created 225 store created
203 00changelog.i created 226 00changelog.i created
204 dotencode 227 dotencode
205 fncache 228 fncache
229 generaldelta
206 revlogv1 230 revlogv1
207 store 231 store
208 232
209 verify that clone also expand urls 233 verify that clone also expand urls
210 234
214 $ checknewrepo "another paths url" 238 $ checknewrepo "another paths url"
215 store created 239 store created
216 00changelog.i created 240 00changelog.i created
217 dotencode 241 dotencode
218 fncache 242 fncache
243 generaldelta
219 revlogv1 244 revlogv1
220 store 245 store
221 246
222 clone bookmarks 247 clone bookmarks
223 248