-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathdoTest
More file actions
executable file
·36 lines (29 loc) · 781 Bytes
/
doTest
File metadata and controls
executable file
·36 lines (29 loc) · 781 Bytes
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
#!/bin/bash
# set up for Unicode in stdout, stderr
export PYTHONIOENCODING=utf8
# run integration test with language definition and test input
if [ $# -eq 0 ]; then
s=test
t=test
elif [ $# -eq 1 ]; then
s=${1}
t=${s}
else
s=${1}
t=${2}
fi
echo ''
echo test application= ${s}, input= ${t}.main.txt
if [ ${s} == 'zhong' ]; then x='-lang=zh' ; fi
if [ ${s} == 'doctor' ]; then x='-noLang' ; fi
if [ ${s} == 'indexing' ]; then x='-d 8' ; fi
if [ ${s} == 'chinese' ]; then x='-g tra' ; fi
if [ ${s} == 'disambig' ]; then x='-noLang -p' ; fi
rm -f *.elly.bin
time python ellyMain.py ${x} ${s} < ${t}.main.txt &> ttaa
egrep FAIL\|$'\r'\|'^ [^ ]' ttaa > tttt
echo ''
echo ' < ACTUAL'
echo ' > EXPECTED'
echo ''
diff -bB tttt ${t}.main.key