summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rwxr-xr-xtests/basic17
-rwxr-xr-xtests/home/testuser/.ssh/proxy-command2
2 files changed, 11 insertions, 8 deletions
diff --git a/tests/basic b/tests/basic
index 8d2b8f8..2befac2 100755
--- a/tests/basic
+++ b/tests/basic
@@ -22,18 +22,16 @@ gpgadmin() {
failed_cleanup() {
# FIXME: can we be more verbose here?
echo 'FAILED!'
+ read -p "press enter to cleanup and remove tmp:"
+
cleanup
}
# cleanup:
cleanup() {
-
- echo
- read -p "press enter to cleanup and remove tmp:"
-
- if ( ps $SSHD_PID >/dev/null ) ; then
+ if ( ps "$SSHD_PID" >/dev/null ) ; then
echo "### stopping still-running sshd..."
- kill $SSHD_PID
+ kill "$SSHD_PID"
fi
echo "### removing temp dir..."
@@ -162,7 +160,12 @@ monkeysphere-server update-users "$USER"
echo "### testuser connecting to sshd socket..."
ssh-agent bash -c \
- "monkeysphere subkey-to-ssh-agent && ssh -F $TEMPDIR/testuser/.ssh/config testhost"
+ "monkeysphere subkey-to-ssh-agent && ssh -F $TEMPDIR/testuser/.ssh/config testhost true"
trap - EXIT
+
+echo
+echo "Monkeysphere basic tests completed successfully!"
+echo
+
cleanup
diff --git a/tests/home/testuser/.ssh/proxy-command b/tests/home/testuser/.ssh/proxy-command
index 630327d..21c66fa 100755
--- a/tests/home/testuser/.ssh/proxy-command
+++ b/tests/home/testuser/.ssh/proxy-command
@@ -5,4 +5,4 @@
# pass this thing the host, the port, and the socket.
monkeysphere-ssh-proxycommand --no-connect "$1" "$2" && \
-socat STDIO UNIX:"$3"
+exec socat STDIO UNIX:"$3"