aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorYong-iL Joh <yong-il.joh@windriver.com>2016-08-25 18:41:49 +0900
committerYong-iL Joh <yong-il.joh@windriver.com>2016-08-26 18:18:29 +0900
commit4248ecf683a27cbb75fa584e63cd786f18ad0013 (patch)
treeeac8d0e3e4fd0d1bd1a392841813622529b7f3ea
parentd0a6b5cc769394e9184a53c724fa2eba11965e65 (diff)
downloadmeta-ivi-4248ecf683a27cbb75fa584e63cd786f18ad0013.tar.gz
meta-ivi-4248ecf683a27cbb75fa584e63cd786f18ad0013.tar.bz2
meta-ivi-4248ecf683a27cbb75fa584e63cd786f18ad0013.zip
test-fw: 2nd updateM-0.2
- reduce messages when test is run in batch mode - add node-health-monitor, node-startup-controller, vsomeip Signed-off-by: Yong-iL Joh <yong-il.joh@windriver.com>
-rw-r--r--meta-ivi-test/recipes-core-ivi/vsomeip/vsomeip/vsomeip_t.inc43
-rw-r--r--meta-ivi-test/recipes-core-ivi/vsomeip/vsomeip_%.bbappend5
-rw-r--r--meta-ivi-test/recipes-extended/common-api/capicxx-perf/capicxx-perf_t.inc22
-rw-r--r--meta-ivi-test/recipes-extended/common-api/common-api-test/common-api-test_t.inc25
-rw-r--r--meta-ivi-test/recipes-extended/dlt-daemon/dlt-daemon/dlt-daemon_t.inc25
-rw-r--r--meta-ivi-test/recipes-extended/node-health-monitor/node-health-monitor/node-health-monitor_t.inc45
-rw-r--r--meta-ivi-test/recipes-extended/node-health-monitor/node-health-monitor_%.bbappend9
-rw-r--r--meta-ivi-test/recipes-extended/node-startup-controller/node-startup-controller/node-startup-controller_t.inc69
-rw-r--r--meta-ivi-test/recipes-extended/node-startup-controller/node-startup-controller_%.bbappend5
-rw-r--r--meta-ivi-test/recipes-extended/node-state-manager/node-state-manager/node-state-manager_t.inc44
-rw-r--r--meta-ivi-test/recipes-extended/persistence-administrator/persistence-administrator/persistence-administrator_t.inc29
-rw-r--r--meta-ivi-test/recipes-extended/persistence-client-library/persistence-client-library/persistence-client-library_t.inc31
-rw-r--r--meta-ivi-test/recipes-extended/persistence-common-object/persistence-common-object/persistence-common-object_t.inc20
-rw-r--r--meta-ivi-test/recipes-multimedia/audiomanager/audiomanager/audiomanager_t.inc24
-rw-r--r--meta-ivi-test/recipes-multimedia/audiomanager/audiomanagerplugins/audiomanagerplugins_t.inc20
-rwxr-xr-xmeta-ivi-test/recipes-yocto-ivi/test-fw/test-fw/test-fw.sh27
16 files changed, 394 insertions, 49 deletions
diff --git a/meta-ivi-test/recipes-core-ivi/vsomeip/vsomeip/vsomeip_t.inc b/meta-ivi-test/recipes-core-ivi/vsomeip/vsomeip/vsomeip_t.inc
new file mode 100644
index 0000000..24788c6
--- /dev/null
+++ b/meta-ivi-test/recipes-core-ivi/vsomeip/vsomeip/vsomeip_t.inc
@@ -0,0 +1,43 @@
+#!/bin/sh
+get_list() {
+ return 6
+}
+
+get_title() {
+ echo "vSOMEIP"
+}
+
+_run_dir=/opt/tests/vsomeip
+_run() {
+ cd ${_run_dir}
+ if [ "x${2}" != "x" ]; then
+ ./${1}_starter.sh >& /tmp/t
+ tail -n 8 /tmp/t | grep -E 'PASS|FAIL'
+ else
+ ./${1}_starter.sh
+ fi
+}
+
+run_1() {
+ _run application_test $*
+}
+
+run_2() {
+ _run big_payload_test_local $*
+}
+
+run_3() {
+ _run external_local_payload_test_client_local $*
+}
+
+run_4() {
+ _run header_factory_test_send_receive $*
+}
+
+run_5() {
+ _run local_payload_test $*
+}
+
+run_6() {
+ _run local_routing_test $*
+}
diff --git a/meta-ivi-test/recipes-core-ivi/vsomeip/vsomeip_%.bbappend b/meta-ivi-test/recipes-core-ivi/vsomeip/vsomeip_%.bbappend
index d1c7fc7..441fdf0 100644
--- a/meta-ivi-test/recipes-core-ivi/vsomeip/vsomeip_%.bbappend
+++ b/meta-ivi-test/recipes-core-ivi/vsomeip/vsomeip_%.bbappend
@@ -1,9 +1,10 @@
#
# for test
#
-#FILESEXTRAPATHS_append := ":${THISDIR}/${PN}"
+FILESEXTRAPATHS_append := ":${THISDIR}/${PN}"
SRC_URI_append += " \
http://googletest.googlecode.com/files/gtest-1.7.0.zip \
+ file://${BPN}_t.inc \
"
SRC_URI[md5sum] = "2d6ec8ccdf5c46b05ba54a9fd1d130d7"
SRC_URI[sha256sum] = "247ca18dd83f53deb1328be17e4b1be31514cedfc1e3424f672bf11fd7e0d60d"
@@ -28,6 +29,8 @@ do_install_append() {
for i in sh json test client service; do
cp -f ${B}/test/*${i} ${D}/opt/tests/${PN}
done
+
+ install -m 0755 ${WORKDIR}/${BPN}_t.inc ${D}/opt/tests/${PN}
}
PACKAGES += "${PN}-test"
diff --git a/meta-ivi-test/recipes-extended/common-api/capicxx-perf/capicxx-perf_t.inc b/meta-ivi-test/recipes-extended/common-api/capicxx-perf/capicxx-perf_t.inc
index 2503c10..09199db 100644
--- a/meta-ivi-test/recipes-extended/common-api/capicxx-perf/capicxx-perf_t.inc
+++ b/meta-ivi-test/recipes-extended/common-api/capicxx-perf/capicxx-perf_t.inc
@@ -7,9 +7,25 @@ get_title() {
echo "Common API C++ test code"
}
-run_1() {
- /opt/tests/capicxx-perf/capicxx-server &
- /opt/tests/capicxx-perf/capicxx-client
+_run_dir=/opt/tests/capicxx-perf
+_run_1() {
+ ${_run_dir}/capicxx-server &
+ ${_run_dir}/capicxx-client
kill -9 `pidof capicxx-server`
sleep 1
}
+
+run_1() {
+ if [ "x${1}" != "x" ]; then
+ _run_1 >& /tmp/t
+ _test_completed=`cat /tmp/t | grep "test completed"`
+ _10000_sent=`cat /tmp/t | grep "sync messages sent" | grep 10000`
+ if [ "x${_test_completed}" != "x" -a "y${_10000_sent}" != "y" ]; then
+ echo " PASSED"
+ else
+ echo " FAILED"
+ fi
+ else
+ _run_1
+ fi
+}
diff --git a/meta-ivi-test/recipes-extended/common-api/common-api-test/common-api-test_t.inc b/meta-ivi-test/recipes-extended/common-api/common-api-test/common-api-test_t.inc
index 8b304f1..1c7cca9 100644
--- a/meta-ivi-test/recipes-extended/common-api/common-api-test/common-api-test_t.inc
+++ b/meta-ivi-test/recipes-extended/common-api/common-api-test/common-api-test_t.inc
@@ -7,11 +7,30 @@ get_title() {
echo "Common API C++ runtime"
}
-run_1() {
- /opt/tests/common-api-test/E05ManagerService &
- /opt/tests/common-api-test/E05ManagerClient &
+_run_dir=/opt/tests/common-api-test
+_run_1() {
+ ${_run_dir}/E05ManagerService &
+ ${_run_dir}/E05ManagerClient &
sleep 5
kill -9 `pidof E05ManagerClient`
kill -9 `pidof E05ManagerService`
sleep 1
}
+
+run_1() {
+ if [ "x${1}" != "x" ]; then
+ _run_1 >& /tmp/t
+ _c1=`cat /tmp/t | grep "Special device 0 detected"`
+ _c2=`cat /tmp/t | grep "Special device 0 removed"`
+ _c3=`cat /tmp/t | grep "Device 1 detected"`
+ _c4=`cat /tmp/t | grep "Device 1 removed"`
+ if [ "x${_c1}" != "x" -a "x${_c2}" != "x" -a \
+ "x${_c3}" != "x" -a "x${_c4}" != "x" ]; then
+ echo " PASSED"
+ else
+ echo " FAILED"
+ fi
+ else
+ _run_1
+ fi
+}
diff --git a/meta-ivi-test/recipes-extended/dlt-daemon/dlt-daemon/dlt-daemon_t.inc b/meta-ivi-test/recipes-extended/dlt-daemon/dlt-daemon/dlt-daemon_t.inc
index 195db76..ab96fa0 100644
--- a/meta-ivi-test/recipes-extended/dlt-daemon/dlt-daemon/dlt-daemon_t.inc
+++ b/meta-ivi-test/recipes-extended/dlt-daemon/dlt-daemon/dlt-daemon_t.inc
@@ -7,10 +7,31 @@ get_title() {
echo "dlt-daemon"
}
+_run_dir=/opt/tests/dlt-daemon
run_1() {
- /opt/tests/dlt-daemon/dlt-test-filetransfer
+ if [ "x${1}" != "x" ]; then
+ ${_run_dir}/dlt-test-filetransfer > /tmp/t
+ _c1=$?
+ if [ "x${_c1}" = "x0" ]; then
+ echo " PASSED"
+ else
+ echo " FAILED"
+ fi
+ else
+ ${_run_dir}/dlt-test-filetransfer
+ fi
}
run_2() {
- /opt/tests/dlt-daemon/dlt-test-user
+ if [ "x${1}" != "x" ]; then
+ ${_run_dir}/dlt-test-user > /tmp/t
+ _c1=`cat /tmp/t | grep -v -E Test.. | grep -v "locally printed"`
+ if [ "x${_c1}" = "x" ]; then
+ echo " PASSED"
+ else
+ echo " FAILED"
+ fi
+ else
+ ${_run_dir}/dlt-test-user
+ fi
}
diff --git a/meta-ivi-test/recipes-extended/node-health-monitor/node-health-monitor/node-health-monitor_t.inc b/meta-ivi-test/recipes-extended/node-health-monitor/node-health-monitor/node-health-monitor_t.inc
new file mode 100644
index 0000000..2afbc92
--- /dev/null
+++ b/meta-ivi-test/recipes-extended/node-health-monitor/node-health-monitor/node-health-monitor_t.inc
@@ -0,0 +1,45 @@
+#!/bin/sh
+get_list() {
+ return 2
+}
+
+get_title() {
+ echo "Node Health Monitor"
+}
+
+_run_dir=/opt/tests/node-health-monitor
+_run_() {
+ systemctl start nsm-dummy
+ node-health-monitor &
+
+ cd ${_run_dir}
+ ./${1}
+
+ kill -9 `pidof node-health-monitor`
+ systemctl stop nsm-dummy
+}
+
+_run() {
+ echo "[ FAILED ] node-head-monitor is not working properly"
+ return 0
+
+ if [ "x${2}" != "x" ]; then
+ _run_ $1 > /tmp/t 2> /tmp/t.err
+ _c1=$?
+ if [ "x${_c1}" = "x0" ]; then
+ echo "[ PASSED ]"
+ else
+ echo "[ FAILED ]"
+ fi
+ else
+ _run_ $1 2> /tmp/t.err
+ fi
+}
+
+run_1() {
+ _run nhm-main-test $*
+}
+
+run_2() {
+ _run nhm-systemd-test $*
+}
diff --git a/meta-ivi-test/recipes-extended/node-health-monitor/node-health-monitor_%.bbappend b/meta-ivi-test/recipes-extended/node-health-monitor/node-health-monitor_%.bbappend
index fa2055a..fbe0ad1 100644
--- a/meta-ivi-test/recipes-extended/node-health-monitor/node-health-monitor_%.bbappend
+++ b/meta-ivi-test/recipes-extended/node-health-monitor/node-health-monitor_%.bbappend
@@ -1,6 +1,11 @@
#
# for test
#
+FILESEXTRAPATHS_append := ":${THISDIR}/${PN}"
+SRC_URI_append += " \
+ file://${BPN}_t.inc \
+ "
+
do_compile_append() {
make -C tst nhm-main-test
make -C tst nhm-systemd-test
@@ -11,6 +16,8 @@ do_install_append() {
install -m 0755 ${S}/tst/nhm-main-test ${D}/opt/tests/${PN}
install -m 0755 ${S}/tst/nhm-systemd-test ${D}/opt/tests/${PN}
ln -s /etc ${D}/opt/tests/cfg
+
+ install -m 0755 ${WORKDIR}/${BPN}_t.inc ${D}/opt/tests/${PN}
}
PACKAGES += "${PN}-test"
@@ -20,6 +27,6 @@ FILES_${PN}-dbg += " \
/opt/tests/${PN}/.debug/* \
"
FILES_${PN}-test = " \
- /opt/tests/${PN}/* \
+ /opt/tests/${PN}/ \
/opt/tests/cfg \
"
diff --git a/meta-ivi-test/recipes-extended/node-startup-controller/node-startup-controller/node-startup-controller_t.inc b/meta-ivi-test/recipes-extended/node-startup-controller/node-startup-controller/node-startup-controller_t.inc
new file mode 100644
index 0000000..6516461
--- /dev/null
+++ b/meta-ivi-test/recipes-extended/node-startup-controller/node-startup-controller/node-startup-controller_t.inc
@@ -0,0 +1,69 @@
+#!/bin/sh
+get_list() {
+ return 1
+}
+
+get_title() {
+ echo "Node Startup Controller"
+}
+
+_run_dir=/opt/tests/node-startup-controller
+_luc_check() {
+ while true; do
+ ${_run_dir}/luc_check.sh > /tmp/t
+ is_nsc=`grep LUC is not required`
+ if [ "x${is_nsc}" != "x" ]; then
+ echo "restart node-startup-controller"
+ systemctl stop node-startup-controller
+ sleep 1
+ systemctl start node-startup-controller
+ else
+ break
+ fi
+ done
+}
+_run_() {
+ systemctl start dlt-receive
+ systemctl start nsm-dummy
+ systemctl start node-startup-controller
+
+ _luc_check
+ ${_run_dir}/${1}
+
+ systemctl stop node-startup-controller
+ systemctl stop nsm-dummy
+ #systemctl stop dlt-receive
+}
+
+_check_luc_test_01() {
+ cat /tmp/t | grep 'NSC-' | grep 'CTRL' > /tmp/t2
+ _c1=`cat /tmp/t2 | grep "Updated LUC to:" | grep app1.unit`
+ _c2=`cat /tmp/t2 | grep "\[Starting LUC group: 0\]"`
+ _c3=`cat /tmp/t2 | grep "\[Starting LUC app: app1.unit\]"`
+ _c4=`cat /tmp/t2 | grep "\[Finished starting LUC app: app1.unit\]"`
+ _c5=`cat /tmp/t2 | grep "\[Finished starting LUC group: 0\]"`
+ if [ "x${_c1}" != "x" -a "x${_c2}" != "x" -a "x${_c3}" != "x" -a \
+ "x${_c4}" != "x" -a "x${_c5}" != "x" ]; then
+ echo "[ PASSED ]"
+ else
+ echo "[ FAILED ]"
+ fi
+}
+
+_run() {
+ if [ "x${2}" != "x" ]; then
+ _run_ ${1}.sh > /tmp/t 2> /tmp/t.err
+ eval _check_${1}
+ else
+ _run_ ${1}.sh 2> /tmp/t.err
+ fi
+}
+
+run_1() {
+ _run luc_test_01 $*
+
+}
+
+run_2() {
+ _run nhm-systemd-test $*
+}
diff --git a/meta-ivi-test/recipes-extended/node-startup-controller/node-startup-controller_%.bbappend b/meta-ivi-test/recipes-extended/node-startup-controller/node-startup-controller_%.bbappend
index c9ccacc..1d8e2a1 100644
--- a/meta-ivi-test/recipes-extended/node-startup-controller/node-startup-controller_%.bbappend
+++ b/meta-ivi-test/recipes-extended/node-startup-controller/node-startup-controller_%.bbappend
@@ -4,16 +4,19 @@
FILESEXTRAPATHS_append := ":${THISDIR}/${PN}"
SRC_URI_append += " \
file://helper.zip \
+ file://${BPN}_t.inc \
"
do_install_append() {
install -d ${D}/opt/tests/${PN}
install -m 0755 ${WORKDIR}/helper/*.sh ${D}/opt/tests/${PN}
install -m 0644 ${WORKDIR}/helper/*.service ${D}/${systemd_unitdir}/system
+
+ install -m 0755 ${WORKDIR}/${BPN}_t.inc ${D}/opt/tests/${PN}
}
FILES_${PN}-nsm-dummy += " \
- /opt/tests/${PN}/* \
+ /opt/tests/${PN}/ \
${systemd_unitdir}/system/example.service \
${systemd_unitdir}/system/hello.service \
"
diff --git a/meta-ivi-test/recipes-extended/node-state-manager/node-state-manager/node-state-manager_t.inc b/meta-ivi-test/recipes-extended/node-state-manager/node-state-manager/node-state-manager_t.inc
index 6ac298c..f68b454 100644
--- a/meta-ivi-test/recipes-extended/node-state-manager/node-state-manager/node-state-manager_t.inc
+++ b/meta-ivi-test/recipes-extended/node-state-manager/node-state-manager/node-state-manager_t.inc
@@ -7,22 +7,50 @@ get_title() {
echo "Node State Manager"
}
+_run_dir=/opt/tests/node-state-manager
+_run_1() {
+ ${_run_dir}/NodeStateTest
+}
+
+_lib=/usr/lib/libNodeStateMachineStub.so
+_lib_t=${_run_dir}/lib/libNodeStateMachineTest.so
+_lib_bak=${_run_dir}/lib/libNodeStateMachineStub.so
run_1() {
- cd /usr/lib
- mv libNodeStateMachineStub.so libNodeStateMachineStub.so.bak
- cp /opt/tests/node-state-manager/lib/libNodeStateMachineTest.so \
- libNodeStateMachineStub.so
+ if [ ! -f ${_lib_bak} ]; then
+ cp ${_lib} ${_run_dir}/lib
+ fi
+ cp ${_lib_t} ${_lib}
ldconfig
sleep 1
systemctl start node-startup-controller
- /opt/tests/node-state-manager/NodeStateTest
+ if [ "x${1}" != "x" ]; then
+ _run_1 > /tmp/t 2> /tmp/t.err
+ _c1=`cat /tmp/t | grep success | wc -l`
+ _c2=`cat /tmp/t | grep failed | wc -l`
+ if [ "x${_c1}" = "x0" ]; then
+ echo "[ FAILED ] ${_c2} tests."
+ elif [ "x${_c2}" = "x0" ]; then
+ echo "[ PASSED ] ${_c1} tests."
+ else
+ echo " ${_c1} PASSED, ${_c2} FAILED"
+ fi
+ else
+ _run_1 2> /tmp/t.err
+ fi
systemctl stop node-startup-controller
- kill -9 `pidof NodeStateManager`
+ _p=`pidof NodeStateManager`
+ if [ "x${_p}" != "x" ]; then
+ kill -9 ${_p} >& /dev/null
+ fi
+ _p=`pidof nsm-dummy`
+ if [ "x${_p}" != "x" ]; then
+ kill -9 ${_p} >& /dev/null
+ fi
- rm -f libNodeStateMachineStub.so
- mv libNodeStateMachineStub.so.bak libNodeStateMachineStub.so
+ rm -f ${_lib}
+ cp ${_lib_bak} ${_lib}
ldconfig
}
diff --git a/meta-ivi-test/recipes-extended/persistence-administrator/persistence-administrator/persistence-administrator_t.inc b/meta-ivi-test/recipes-extended/persistence-administrator/persistence-administrator/persistence-administrator_t.inc
index 0e3a65c..d9ff540 100644
--- a/meta-ivi-test/recipes-extended/persistence-administrator/persistence-administrator/persistence-administrator_t.inc
+++ b/meta-ivi-test/recipes-extended/persistence-administrator/persistence-administrator/persistence-administrator_t.inc
@@ -7,21 +7,38 @@ get_title() {
echo "persistence-administrator"
}
+_run_dir=/opt/tests/persistence-administrator
+_run_1() {
+ persadmin_tool install /Data/Data.tar.gz > /tmp/t
+ ${_run_dir}/pers_admin_test_framework
+}
+
run_1() {
- echo "error!"
- echo "segfault at 7fa2ac0b6010 ip 000000364d88e130 sp 00007fa2ae0f2aa8 error 4 in libc-2.23.so[364d800000+197000]"
- exit -1
+ echo "[ FAILED ] segfault at 7fa2ac0b6010 ip 000000364d88e130 sp 00007fa2ae0f2aa8 error 4 in libc-2.23.so[364d800000+197000]"
+ return 0
if [ ! -d /tmp/PAS ]; then
rm -f /tmp/PAS
mkdir -p /tmp/PAS
fi
- cp /opt/tests/persistence-administrator/resource*.tar.gz /tmp/PAS/
+ cp ${_run_dir}/resource*.tar.gz /tmp/PAS/
systemctl restart dlt-dbus
systemctl restart dlt-example-user
systemctl restart pas-daemon
systemctl restart node-startup-controller
- persadmin_tool install /Data/Data.tar.gz
- /opt/tests/persistence-administrator/pers_admin_test_framework
+ if [ "x${1}" != "x" ]; then
+ _run_1 > /tmp/t
+ _c1=`cat /tmp/t | grep :P: | wc -l`
+ _c2=`cat /tmp/t | grep :F: | wc -l`
+ if [ "x${_c1}" = "x0" ]; then
+ echo "[ FAILED ] ${_c2} tests."
+ elif [ "x${_c2}" = "x0" ]; then
+ echo "[ PASSED ] ${_c1} tests."
+ else
+ echo " ${_c1} PASSED, ${_c2} FAILED"
+ fi
+ else
+ _run_1
+ fi
}
diff --git a/meta-ivi-test/recipes-extended/persistence-client-library/persistence-client-library/persistence-client-library_t.inc b/meta-ivi-test/recipes-extended/persistence-client-library/persistence-client-library/persistence-client-library_t.inc
index 7fbec91..825fa32 100644
--- a/meta-ivi-test/recipes-extended/persistence-client-library/persistence-client-library/persistence-client-library_t.inc
+++ b/meta-ivi-test/recipes-extended/persistence-client-library/persistence-client-library/persistence-client-library_t.inc
@@ -7,11 +7,30 @@ get_title() {
echo "persisitence-client-library"
}
+_run_dir=/opt/tests/persistence-client-library
+_run_1() {
+ persadmin_tool install /Data/Data.tar.gz > /tmp/t
+ ${_run_dir}/persistence_client_library_test
+}
+
run_1() {
- systemctl restart dlt-dbus
- systemctl restart dlt-example-user
- systemctl restart pas-daemon
- systemctl restart node-startup-controller
- persadmin_tool install /Data/Data.tar.gz
- /opt/tests/persistence-client-library/persistence_client_library_test
+ #systemctl restart dlt-dbus
+ #systemctl restart dlt-example-user
+ #systemctl restart pas-daemon
+ #systemctl restart node-startup-controller
+ if [ "x${1}" != "x" ]; then
+ _run_1 > /tmp/t
+ _c1=`cat /tmp/t | grep :P: | wc -l`
+ _c2=`cat /tmp/t | grep :F: | wc -l`
+ if [ "x${_c1}" = "x0" ]; then
+ echo "[ FAILED ] ${_c2} tests."
+ elif [ "x${_c2}" = "x0" ]; then
+ echo "[ PASSED ] ${_c1} tests."
+ else
+ echo " ${_c1} PASSED, ${_c2} FAILED"
+ fi
+ else
+ _run_1
+ fi
+ killall -9 nsm-dummy
}
diff --git a/meta-ivi-test/recipes-extended/persistence-common-object/persistence-common-object/persistence-common-object_t.inc b/meta-ivi-test/recipes-extended/persistence-common-object/persistence-common-object/persistence-common-object_t.inc
index c113bd3..bd45a3b 100644
--- a/meta-ivi-test/recipes-extended/persistence-common-object/persistence-common-object/persistence-common-object_t.inc
+++ b/meta-ivi-test/recipes-extended/persistence-common-object/persistence-common-object/persistence-common-object_t.inc
@@ -7,6 +7,24 @@ get_title() {
echo "persisitence-common-object"
}
+_run_dir=/opt/tests/persistence-common-object
+_run_1() {
+ ${_run_dir}/test_pco_key_value_store
+}
+
run_1() {
- /opt/tests/persistence-common-object/test_pco_key_value_store
+ if [ "x${1}" != "x" ]; then
+ _run_1 > /tmp/t
+ _c1=`cat /tmp/t | grep :P: | wc -l`
+ _c2=`cat /tmp/t | grep :F: | wc -l`
+ if [ "x${_c1}" = "x0" ]; then
+ echo "[ FAILED ] ${_c2} tests."
+ elif [ "x${_c2}" = "x0" ]; then
+ echo "[ PASSED ] ${_c1} tests."
+ else
+ echo " ${_c1} PASSED, ${_c2} FAILED"
+ fi
+ else
+ _run_1
+ fi
}
diff --git a/meta-ivi-test/recipes-multimedia/audiomanager/audiomanager/audiomanager_t.inc b/meta-ivi-test/recipes-multimedia/audiomanager/audiomanager/audiomanager_t.inc
index 99edf49..ea9b942 100644
--- a/meta-ivi-test/recipes-multimedia/audiomanager/audiomanager/audiomanager_t.inc
+++ b/meta-ivi-test/recipes-multimedia/audiomanager/audiomanager/audiomanager_t.inc
@@ -7,30 +7,40 @@ get_title() {
echo "audiomanager"
}
+_run_dir=/opt/tests/audiomanager
+_run() {
+ if [ "x${2}" != "x" ]; then
+ ${_run_dir}/$1 > /tmp/t
+ tail /tmp/t | grep -E 'PASS|FAIL'
+ else
+ ${_run_dir}/$1
+ fi
+}
+
run_1() {
- /opt/tests/audiomanager/AmControlInterfaceTest
+ _run AmControlInterfaceTest $*
}
run_2() {
- /opt/tests/audiomanager/AmMapHandlerTest
+ _run AmMapHandlerTest $*
}
run_3() {
- /opt/tests/audiomanager/AmRouterMapTest
+ _run AmRouterMapTest $*
}
run_4() {
- /opt/tests/audiomanager/AmRouterTest
+ _run AmRouterTest $*
}
run_5() {
- /opt/tests/audiomanager/AmRoutingInterfaceTest
+ _run AmRoutingInterfaceTest $*
}
run_6() {
- /opt/tests/audiomanager/AmSocketHandlerTest
+ _run AmSocketHandlerTest $*
}
run_7() {
- /opt/tests/audiomanager/AmTelnetServerTest
+ _run AmTelnetServerTest $*
}
diff --git a/meta-ivi-test/recipes-multimedia/audiomanager/audiomanagerplugins/audiomanagerplugins_t.inc b/meta-ivi-test/recipes-multimedia/audiomanager/audiomanagerplugins/audiomanagerplugins_t.inc
index ebd8958..a4111e3 100644
--- a/meta-ivi-test/recipes-multimedia/audiomanager/audiomanagerplugins/audiomanagerplugins_t.inc
+++ b/meta-ivi-test/recipes-multimedia/audiomanager/audiomanagerplugins/audiomanagerplugins_t.inc
@@ -4,21 +4,31 @@ get_list() {
}
get_title() {
- echo "AudioManagerPlugins"
+ echo "audiomanagerplugins"
+}
+
+_run_dir=/opt/tests/audiomanagerplugins
+_run() {
+ if [ "x${2}" != "x" ]; then
+ ${_run_dir}/$1 > /tmp/t
+ tail /tmp/t | grep -E 'PASS|FAIL'
+ else
+ ${_run_dir}/$1
+ fi
}
run_1() {
- /opt/tests/AudioManagerPlugins/AmCommandSenderCAPITest
+ _run AmCommandSenderCAPITest $*
}
run_2() {
- /opt/tests/AudioManagerPlugins/AmControlReceiverShadowTest
+ _run AmControlReceiverShadowTest $*
}
run_3() {
- /opt/tests/AudioManagerPlugins/AmRoutingInterfaceCAPITests
+ _run AmRoutingInterfaceCAPITests $*s
}
run_4() {
- /opt/tests/AudioManagerPlugins/AmRoutingReceiveAsyncTest
+ _run AmRoutingReceiveAsyncTest $*
}
diff --git a/meta-ivi-test/recipes-yocto-ivi/test-fw/test-fw/test-fw.sh b/meta-ivi-test/recipes-yocto-ivi/test-fw/test-fw/test-fw.sh
index bfd29b7..b2f4c3e 100755
--- a/meta-ivi-test/recipes-yocto-ivi/test-fw/test-fw/test-fw.sh
+++ b/meta-ivi-test/recipes-yocto-ivi/test-fw/test-fw/test-fw.sh
@@ -1,7 +1,23 @@
#!/bin/bash
# create dbus-session
-dbus-launch >& /tmp/t
-export `grep -r DBUS_SESSION_BUS_ADDRESS /tmp/t`
+dbus_live_p() {
+ dbus-send --bus=$1 \
+ --dest=org.freedesktop.DBus --type=method_call --print-reply \
+ /org/freedesktop/DBus org.freedesktop.DBus.ListNames > /tmp/dbus_check
+}
+
+if [ -f /tmp/dbus_test-fw ]; then
+ _bus_str=`grep -r DBUS_SESSION_BUS_ADDRESS /tmp/dbus_test-fw`
+ _bus_addr=`echo ${_bus_str} | awk -F_BUS_ADDRESS= '{print $2}'`
+ dbus_live_p ${_bus_addr}
+ _dbus_live_p=`grep "method return" /tmp/dbus_check`
+ if [ "x${_dbus_live_p}" = "x" ]; then
+ dbus-launch >& /tmp/dbus_test-fw
+ fi
+else
+ dbus-launch >& /tmp/dbus_test-fw
+fi
+export `grep -r DBUS_SESSION_BUS_ADDRESS /tmp/dbus_test-fw`
test_list=`ls /opt/tests/*/*_t.inc | awk -F/ '{print $4}' | awk -F_t '{print $1}'`
@@ -16,8 +32,8 @@ _test_run() {
cnt=$?
echo "[ number of tests:" $cnt "]"
for k in `seq $cnt`; do
- echo "[" run_${k} "]"
- eval run_${k}
+ echo -n "[" run_${k} "]"
+ eval run_${k} "no_verbose_output"
done
else
echo "[" run_${n} "]"
@@ -57,4 +73,5 @@ for i in $test_list; do
continue;
fi
_test_run
-done \ No newline at end of file
+ sleep 2
+done