summaryrefslogtreecommitdiffstats
path: root/tdewallet/backend/tests/backendtest.sh
diff options
context:
space:
mode:
authorSlávek Banko <slavek.banko@axis.cz>2017-02-01 01:57:20 +0100
committerSlávek Banko <slavek.banko@axis.cz>2017-02-01 01:57:30 +0100
commitdf203a23f4d96fae5fbc61bb180c4db8f63e63ae (patch)
tree798af92473cec0f7366e5835cac77f99e28dbb59 /tdewallet/backend/tests/backendtest.sh
parent7cc97cb18734939136579c086bf6758f3a4c18ad (diff)
downloadtdelibs-df203a23f4d96fae5fbc61bb180c4db8f63e63ae.tar.gz
tdelibs-df203a23f4d96fae5fbc61bb180c4db8f63e63ae.zip
testing: Run tests that use DCOP in a temporary home
Signed-off-by: Slávek Banko <slavek.banko@axis.cz>
Diffstat (limited to 'tdewallet/backend/tests/backendtest.sh')
-rw-r--r--tdewallet/backend/tests/backendtest.sh18
1 files changed, 18 insertions, 0 deletions
diff --git a/tdewallet/backend/tests/backendtest.sh b/tdewallet/backend/tests/backendtest.sh
new file mode 100644
index 000000000..d3a6ef0e1
--- /dev/null
+++ b/tdewallet/backend/tests/backendtest.sh
@@ -0,0 +1,18 @@
+#!/bin/sh
+
+# create temporary home
+export HOME=$PWD/test-home
+mkdir $HOME
+
+# run dcop server
+../../../dcop/dcopserver --nofork &
+DCOP_SERVER_PID=$!
+
+# perform test
+./backendtest
+STATE=$?
+
+# cleanup
+kill $DCOP_SERVER_PID
+rm -fr test-home
+exit $STATE