##// END OF EJS Templates
largefiles: add tests for uncovered codepaths (issue3092)...
Levi Bard -
r15810:3d11da21 default
parent child Browse files
Show More
@@ -3,6 +3,7 b''
3 3 > largefiles =
4 4 > share =
5 5 > graphlog =
6 > mq =
6 7 > [largefiles]
7 8 > minsize = 0.5
8 9 > patterns = **.other
@@ -18,21 +19,47 b''
18 19 > EOF
19 20 $ mkdir sub
20 21 $ dd if=/dev/zero bs=1k count=256 > large 2> /dev/null
22 $ dd if=/dev/zero bs=1k count=256 > large2 2> /dev/null
21 23 $ echo normal > normal1
22 24 $ echo alsonormal > sub/normal2
23 25 $ dd if=/dev/zero bs=1k count=10 > sub/maybelarge.dat 2> /dev/null
24 26 $ hg addremove
25 27 adding large
28 adding large2
26 29 adding normal1
27 30 adding sub/maybelarge.dat
28 31 adding sub/normal2
29 32 $ hg commit -m"add large, normal1" large normal1
30 33 $ hg commit -m"add sub/*" sub
34 Test tag parsing
35 $ cat >> .hgtags <<EOF
36 > IncorrectlyFormattedTag!
37 > invalidhash sometag
38 > 0123456789abcdef anothertag
39 > EOF
40 $ hg add .hgtags
41 $ hg commit -m"add large2" large2 .hgtags
42 $ hg rename large2 large3
43 Test link+rename largefile codepath
44 $ ln -sf large large3
45 $ hg commit -m"make large2 a symlink" large2 large3
31 46 $ [ -d .hg/largefiles ] && echo fail || echo pass
32 47 pass
33 48 $ cd ..
34 49 $ hg lfconvert --size 0.2 bigfile-repo largefiles-repo
35 50 initializing destination largefiles-repo
51 skipping incorrectly formatted tag IncorrectlyFormattedTag!
52 skipping incorrectly formatted id invalidhash
53 no mapping for id 0123456789abcdef
54 abort: renamed/copied largefile large3 becomes symlink
55 [255]
56 $ cd bigfile-repo
57 $ hg strip --no-backup 2
58 0 files updated, 0 files merged, 2 files removed, 0 files unresolved
59 $ cd ..
60 $ rm -rf largefiles-repo
61 $ hg lfconvert --size 0.2 bigfile-repo largefiles-repo
62 initializing destination largefiles-repo
36 63
37 64 "lfconvert" converts content correctly
38 65 $ cd largefiles-repo
General Comments 0
You need to be logged in to leave comments. Login now