4 TESTDIR
=$(readlink -f $(dirname $0))
7 configarchitecture
'i386'
9 buildsimplenativepackage
'coolstuff' 'all' '1.0' 'unstable'
15 rm -rf rootdir
/var
/lib
/apt
/lists
17 msgtest
'No download of non-existent locals' 'with Index'
18 LC_ALL
="" aptget update
-o Acquire
::Languages
=en
| grep -q -e 'Translation-[^e][^n] ' && msgfail
|| msgpass
19 rm -rf rootdir
/var
/lib
/apt
/lists
21 msgtest
'Download of existent locals' 'with Index'
22 LC_ALL
="" aptget update
| grep -q -e 'Translation-en ' && msgpass
|| msgfail
23 rm -rf rootdir
/var
/lib
/apt
/lists
25 msgtest
'Download of en in LC_ALL=C' 'with Index'
26 LC_ALL
=C aptget update
| grep -q -e 'Translation-en ' && msgpass
|| msgfail
27 rm -rf rootdir
/var
/lib
/apt
/lists
29 msgtest
'Download of en as forced language' 'with Index'
30 aptget update
-o Acquire
::Languages
=en
| grep -q -e 'Translation-en ' && msgpass
|| msgfail
31 rm -rf rootdir
/var
/lib
/apt
/lists
33 msgtest
'Download of nothing else in forced language' 'with Index'
34 aptget update
-o Acquire
::Languages
=en
| grep -q -e 'Translation-[^e][^n] ' && msgfail
|| msgpass
35 rm -rf rootdir
/var
/lib
/apt
/lists
37 msgtest
'Download no Translation- if forced language is non-existent' 'with Index'
38 aptget update
-o Acquire
::Languages
=ast_DE
| grep -q -e 'Translation-' && msgfail
|| msgpass
39 rm -rf rootdir
/var
/lib
/apt
/lists
41 msgtest
'Download of nothing if none is forced' 'with Index'
42 aptget update
-o Acquire
::Languages
=none
| grep -q -e 'Translation' && msgfail
|| msgpass
43 rm -rf rootdir
/var
/lib
/apt
/lists
45 sed -i '/i18n\/Translation-.*$/ d' $(find aptarchive -name 'Release')
48 msgtest
'Download of en as forced language' 'without Index'
49 aptget update
-o Acquire
::Languages
=en
| grep -q -e 'Translation-en ' && msgpass
|| msgfail
50 rm -rf rootdir
/var
/lib
/apt
/lists
52 msgtest
'Download of nothing else in forced language' 'without Index'
53 aptget update
-o Acquire
::Languages
=en
| grep -q -e 'Translation-[^e][^n] ' && msgfail
|| msgpass
54 rm -rf rootdir
/var
/lib
/apt
/lists
56 msgtest
'Download of ast_DE as forced language' 'without Index'
57 aptget update
-o Acquire
::Languages
=ast_DE
| grep -q -e 'Translation-ast_DE$' && msgpass
|| msgfail
58 rm -rf rootdir
/var
/lib
/apt
/lists
60 msgtest
'Download of nothing else in forced language' 'without Index'
61 aptget update
-o Acquire
::Languages
=ast_DE
| grep -q -e 'Translation-[^a][^s]' && msgfail
|| msgpass
62 rm -rf rootdir
/var
/lib
/apt
/lists
64 msgtest
'Download of nothing if none is forced' 'without Index'
65 aptget update
-o Acquire
::Languages
=none
| grep -q -e 'Translation' && msgfail
|| msgpass
66 rm -rf rootdir
/var
/lib
/apt
/lists
68 mkdir -p rootdir
/var
/lib
/apt
/lists
69 touch rootdir
/var
/lib
/apt
/lists
/localhost
:8080_dists_unstable_main_i18n_Translation
-ast_DE
71 msgtest
'Download of builtin files' 'without Index'
72 aptget update
| grep -q -e 'Translation-ast_DE' && msgpass
|| msgfail
73 rm -rf rootdir
/var
/lib
/apt
/lists
75 mkdir -p rootdir
/var
/lib
/apt
/lists
76 touch rootdir
/var
/lib
/apt
/lists
/localhost
:8080_dists_unstable_main_i18n_Translation
-ast_DE
78 msgtest
'Download of nothing (even builtin) if none is forced' 'without Index'
79 aptget update
-o Acquire
::Languages
=none
| grep -q -e 'Translation' && msgfail
|| msgpass
80 rm -rf rootdir
/var
/lib
/apt
/lists