summaryrefslogtreecommitdiff
path: root/test_bootstrap
diff options
context:
space:
mode:
authorTomas Touceda <chiiph@leap.se>2013-04-25 12:12:02 -0300
committerTomas Touceda <chiiph@leap.se>2013-04-25 12:12:02 -0300
commita0df6b9b8fbf7d4db53bb21f379cb1941d823a5b (patch)
tree688a9442985c1e849a301dd85b1988c38643c7e5 /test_bootstrap
parent28a5992e9b4c5a9a080ad39ba6483843c99f1c47 (diff)
Reorder files, normalize repo and add sample config
Diffstat (limited to 'test_bootstrap')
-rwxr-xr-xtest_bootstrap39
1 files changed, 0 insertions, 39 deletions
diff --git a/test_bootstrap b/test_bootstrap
deleted file mode 100755
index f072d10..0000000
--- a/test_bootstrap
+++ /dev/null
@@ -1,39 +0,0 @@
-#!/bin/bash
-##############################################################################
-#
-# test_bootstrap
-# --------------
-# Test that the bootstrap script works correctly by making a temporary new
-# user.
-#
-# @author Isis Agora Lovecruft, 0x2cdb8b35
-# @date 18 February 2013
-# @version 0.0.1
-##############################################################################
-
-set -ex -
-
-HERE=$(pwd)
-TEST_USER=bootstraptester
-
-echo "Creating new user: "'"'"${TEST_USER}"'"'""
-sudo adduser --home /home/${TEST_USER} --shell /bin/bash ${TEST_USER} && \
- echo -e "notsecure\nnotsecure\n" | sudo passwd ${TEST_USER}
-
-echo 'Copying boostrap script to new user home directory...'
-sudo cp ${HERE}/bootstrap /home/${TEST_USER}/bootstrap && \
- sudo chown ${TEST_USER}:${TEST_USER} /home/${TEST_USER}/bootstrap
-
-echo 'Logging in as new user and executing bootstrap script...'
-echo 'Executing test of bootstrap script...'
-## -S pulls password from stdin
-echo -e "notsecure\n" | sudo -S -H -u ${TEST_USER} -i /home/${TEST_USER}/bootstrap
-
-if [[ "$?" != 0 ]] ; then
- echo 'Error while testing bootstrap...'
-else
- echo 'Test of bootstrap successful.'
-fi
-
-echo "Deleting user: "'"'"${TEST_USER}"'"'""
-sudo deluser --remove-home ${TEST_USER}