summaryrefslogtreecommitdiff
path: root/test/stop_scorsh.sh
diff options
context:
space:
mode:
authorKatolaZ <katolaz@freaknet.org>2017-08-09 21:29:45 +0100
committerKatolaZ <katolaz@freaknet.org>2017-08-09 21:29:45 +0100
commit33b7c33ab447a0463e414c6cf8f9a2cd2d047a20 (patch)
treebaeaae3eca65536bbe17ad9fe196c7383eafd4da /test/stop_scorsh.sh
parent231beb5c3fc50f40e31b9e00237c67f267188057 (diff)
added more tests about basic scorsh setup
Diffstat (limited to 'test/stop_scorsh.sh')
-rwxr-xr-xtest/stop_scorsh.sh20
1 files changed, 20 insertions, 0 deletions
diff --git a/test/stop_scorsh.sh b/test/stop_scorsh.sh
new file mode 100755
index 0000000..353b027
--- /dev/null
+++ b/test/stop_scorsh.sh
@@ -0,0 +1,20 @@
+#!/bin/sh
+
+. ./scorsh_functions
+
+## is the daemon running?
+cd ${SCORSH_APP}
+is_running=$(ps $(cat scorsh.pid) | grep -c scorshd )
+cd - >/dev/null
+check "[ \"${is_running}\" = \"1\" ]" $0 "is_scorshd_running"
+
+
+## stop the scorsh daemon
+cd ${SCORSH_APP}
+kill -15 $(cat scorsh.pid)
+ret=$?
+rm scorsh.pid
+cd - >/dev/null
+check "[ $ret -eq 0 ]" $0 ""
+
+return_results