diff options
author | 2016-08-25 19:26:28 +0200 | |
---|---|---|
committer | 2016-08-25 23:54:21 +0200 | |
commit | 677813c6a26eca5629ef8201fd0616511400a99e (patch) | |
tree | c1a68987474126839e8f1bcc01274994a50120b8 /src/tests | |
parent | 15c3a8b1ef47127d30d8b5f26f9d7622a0b72656 (diff) |
add algorithm to seek for locale files
Change-Id: Ie4355db29b157b13c4d93011337b15ca3e5d2571
Diffstat (limited to 'src/tests')
-rwxr-xr-x | src/tests/test-locale-root.sh | 41 |
1 files changed, 41 insertions, 0 deletions
diff --git a/src/tests/test-locale-root.sh b/src/tests/test-locale-root.sh new file mode 100755 index 00000000..d09b0399 --- /dev/null +++ b/src/tests/test-locale-root.sh @@ -0,0 +1,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 + |