equal
deleted
inserted
replaced
1 #!/bin/sh |
|
2 |
|
3 echo % prepare repo |
|
4 hg init a |
|
5 cd a |
|
6 echo "some text" > FOO.txt |
|
7 echo "another text" > bar.txt |
|
8 echo "more text" > QUICK.txt |
|
9 hg add |
|
10 hg ci -mtest1 |
|
11 |
|
12 echo |
|
13 echo % verify |
|
14 hg verify |
|
15 |
|
16 echo |
|
17 echo % verify with journal |
|
18 touch .hg/store/journal |
|
19 hg verify |
|
20 rm .hg/store/journal |
|
21 |
|
22 echo |
|
23 echo % introduce some bugs in repo |
|
24 cd .hg/store/data |
|
25 mv _f_o_o.txt.i X_f_o_o.txt.i |
|
26 mv bar.txt.i xbar.txt.i |
|
27 rm _q_u_i_c_k.txt.i |
|
28 |
|
29 echo |
|
30 echo % verify |
|
31 hg verify |
|
32 |
|
33 cd .. |
|
34 |
|
35 echo % test revlog corruption |
|
36 hg init b |
|
37 cd b |
|
38 |
|
39 touch a |
|
40 hg add a |
|
41 hg ci -m a |
|
42 |
|
43 echo 'corrupted' > b |
|
44 dd if=.hg/store/data/a.i of=start bs=1 count=20 2>/dev/null |
|
45 cat start b > .hg/store/data/a.i |
|
46 |
|
47 echo |
|
48 echo % verify |
|
49 hg verify |
|
50 |
|
51 exit 0 |
|