blob: 565ac17ace5dd4fedc5a28d3ec1540e0b4954889 (
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
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
|
#!/bin/sh
#
# Weston IVI Plugin Test
#
# Remark: This examination premises that Weston does not run.
# 1 Delete log file
rm -fr ../tests/testlog
mkdir ../tests/testlog
# 2 Start Pseudo event device (for Touch Panel)
../tools/ico_send_inputevent -d -mq=5551 2> ../tests/testlog/event_log.log &
sleep 1
# 3 Set Environment for Test
export WESTON_IVI_PLUGIN_DIR="../src/.libs"
# 4 Start Weston
export XDG_CONFIG_HOME="../tests"
export XDG_RUNTIME_DIR="/run/user/5000"
MOD_DIR="$PWD/../src/.libs"
/usr/bin/weston --tty=2 --modules=$MOD_DIR/ico_plugin_loader.so --idle-time=0 $WESTON_BACKEND --log=../tests/testlog/weston.log &
sleep 1
# 5 Set library path
export LD_LIBRARY_PATH=../src/.libs:$LD_LIBRARY_PATH
# 6 Start test-homescreen
../tests/test-homescreen < ../tests/testdata/hs_inputtest.dat 2> ../tests/testlog/test-homescreen.log
# 7 End of Test
sleep 1
/usr/bin/killall weston
/usr/bin/killall ico_send_inputevent
sleep 1
# 8 Check Error
FOUND_ERR=0
/bin/grep "ERR>" testlog/*
if [ "$?" != "1" ] ; then
FOUND_ERR=1
fi
/bin/grep "WRN>" testlog/*
if [ "$?" != "1" ] ; then
FOUND_ERR=1
fi
/bin/grep "Error" testlog/*
if [ "$?" != "1" ] ; then
FOUND_ERR=1
fi
/bin/grep "error" testlog/* | /bin/grep -v "error_but_no_problem_for_test" | /bin/grep -v "failed to restore kb mode:" | /bin/grep -v "failed to set KD_TEXT mode on tty:"
if [ "$?" != "1" ] ; then
FOUND_ERR=1
fi
/bin/grep "Fail" testlog/* | /bin/grep -v "error_but_no_problem_for_test" | /bin/grep -v "initialize backlight"
if [ "$?" != "1" ] ; then
FOUND_ERR=1
fi
if [ $FOUND_ERR = 0 ] ; then
echo "Weston IVI Plugin Test: OK"
else
echo "Weston IVI Plugin Test: ERROR"
fi
|