summaryrefslogtreecommitdiff
path: root/tests/input-controller-test
diff options
context:
space:
mode:
authorShibata Makoto <shibata@mac.tec.toyota.co.jp>2013-04-26 20:39:06 +0900
committerShibata Makoto <shibata@mac.tec.toyota.co.jp>2013-04-26 20:39:41 +0900
commit0f80d0012c6f40ebb02622e058911e9d581bc4f2 (patch)
treeb184a9305d983642adfdc4855a49d714541033b9 /tests/input-controller-test
downloadico-uxf-device-input-controller-0f80d0012c6f40ebb02622e058911e9d581bc4f2.tar.gz
ico-uxf-device-input-controller-0f80d0012c6f40ebb02622e058911e9d581bc4f2.tar.bz2
ico-uxf-device-input-controller-0f80d0012c6f40ebb02622e058911e9d581bc4f2.zip
Updated package changelog.
Change-Id: I24b2c18efcc223a2abea06b317f0b54c976841d9 Signed-off-by: Shibata Makoto <shibata@mac.tec.toyota.co.jp>
Diffstat (limited to 'tests/input-controller-test')
-rwxr-xr-xtests/input-controller-test85
1 files changed, 85 insertions, 0 deletions
diff --git a/tests/input-controller-test b/tests/input-controller-test
new file mode 100755
index 0000000..218335c
--- /dev/null
+++ b/tests/input-controller-test
@@ -0,0 +1,85 @@
+#!/bin/sh
+#
+# Device Input Controller Test
+#
+# Remark: This examination premises that Weston does not run.
+
+# 1 Delete log file
+rm -fr ../tests/testlog/*
+
+# 2 Start Pseudo event device (for Touch Panel and Jyostick)
+../tests/test-send_event -device=ico_test_touch -d -mq=55551 2> ../tests/testlog/event_log_touch.log &
+../tests/test-send_event -device=ico_test_joystick -d -J -mq=55552 2> ../tests/testlog/event_log_joystic.log &
+sleep 1
+
+# 3 Start Device Input Controllers
+export CALIBRATOIN_CONF="../egalax_calibration.conf"
+export ICTL_TOUCH_DEV="ico_test_touch"
+#../touch_egalax/ico_ictl-touch_egalax -d -L ico_test_touch 2> ../tests/testlog/touch_egalax.log &
+../touch_egalax/ico_ictl-touch_egalax -d -L > ../tests/testlog/touch_egalax.log 2>&1 &
+sleep 0.5
+export ICTL_GTFORCE_CONF="../joystick_gtforce.conf"
+export ICTL_GTFORCE_DEV="ico_test_joystick"
+#../joystick_gtforce/ico_ictl-joystick_gtforce -d -l ico_test_joystick 2> ../tests/testlog/joystick_gtforce.log &
+../joystick_gtforce/ico_ictl-joystick_gtforce -d -l > ../tests/testlog/joystick_gtforce.log 2>&1 &
+sleep 1
+
+# 4 Weston/Wayland Envionment
+export XDG_RUNTIME_DIR=/tmp/run-root
+export QT_QPA_PLATFORM=wayland
+export ELM_ENGINE=wayland_egl
+export ECORE_EVAS_ENGINE=wayland_egl
+#export ELM_ENGINE=wayland_shm
+#export ECORE_EVAS_ENGINE=wayland_shm
+export EVAS_FONT_DPI=72
+export ECORE_IMF_MODULE=isf
+export ELM_MODULES="ctxpopup_copypasteUI>entry/api:datetime_input_ctxpopup>datetime/api"
+export ELM_SCALE="0.7"
+export ELM_PROFILE=mobile
+
+# 5 Start Weston
+export XDG_CONFIG_HOME="../tests"
+/usr/bin/weston --backend=drm-backend.so --idle-time=0 --log=../tests/testlog/weston.log &
+sleep 1
+
+# 5 Start test-homescreen
+../tests/test-homescreen < ../tests/testdata/hs_alltest.dat 2> ../tests/testlog/test-homescreen.log
+
+# 6 End of Test
+sleep 1
+/usr/bin/killall weston
+/usr/bin/killall test-send_event
+/usr/bin/killall test-send_event
+/usr/bin/killall ico_ictl-touch_egalax
+/usr/bin/killall ico_ictl-joystick_gtforce
+sleep 1
+
+# 9 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"
+if [ "$?" != "1" ] ; then
+ FOUND_ERR=1
+fi
+/bin/grep "Fail" testlog/* | /bin/grep -v "error_but_no_problem_for_test"
+if [ "$?" != "1" ] ; then
+ FOUND_ERR=1
+fi
+
+if [ $FOUND_ERR = 0 ] ; then
+ echo "Device Input Controller Test: OK"
+else
+ echo "Device Input Controller Test: ERROR"
+fi
+