aboutsummaryrefslogtreecommitdiffstats
path: root/src/tests/test-locale-root.sh
blob: d09b0399fe65842b1168520c3dae7b81a8cb2360 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
#!/bin/bash

files="
locales/fr/titi
locales/fr-FR/titi
locales/fr-BE/titi
locales/fr-CA/titi
locales/en/titi
locales/en-GB/titi
locales/en-US/titi
locales/zh-hans-cn/a.gif
locales/zh-hans-cn/f.gif
locales/zh-hans/a.gif
locales/zh-hans/b.gif
locales/zh/a.gif
locales/zh/b.gif
locales/zh/c.gif
a.gif
b.gif
c.gif
d.gif
index.html
config.xml
"


testdir=testdir$$

rm -rf $testdir
for f in $files
do
	mkdir -p $testdir/$(dirname $f)
	echo $f > $testdir/$f
done

cc -o $testdir/lr ../locale-root.c -D TEST_locale_root -g
valgrind $testdir/lr @$testdir +zh-hans-cn a.gif b.gif c.gif d.gif +en-US a.gif b.gif c.gif d.gif +zh-hans-cn a.gif b.gif c.gif d.gif


rm -rf $testdir