diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
index 7e86b2c14baf500ba293d7209d62f6592d8f900e..c46648c4391065e18af7460c004c3597c15d2110 100644
--- a/.gitlab-ci.yml
+++ b/.gitlab-ci.yml
@@ -30,4 +30,4 @@ test:
     - apt update && apt -y install libncurses-dev libmodbus-dev libsqlite3-dev libident netcat sqlite3
     - useradd testuser && chown -R testuser .
   script:
-    - cd tests && su -l -c './TEST_basic.sh' testuser
+    - cd tests && su -c './TEST_basic.sh' testuser
diff --git a/tests/TEST_basic.sh b/tests/TEST_basic.sh
index d128f8ddc2e7cbbd8f1b5165e4e6531e45742f40..463693065f49cce1b2b70b847f575e46d8bf09fd 100755
--- a/tests/TEST_basic.sh
+++ b/tests/TEST_basic.sh
@@ -4,21 +4,8 @@ TESTNAME=basic
 
 . _common.sh
 
-# (CI runs as root, and root is auto-added by databse creation)
-if [[ "x$USER" != "xroot" ]]; then
-	# Ensure that the databse doesn't already contain the current user
-	# - 1. Protects against running the test against the production database
-	# - 2. Allows adding the current user as an admin
-	if $DISPENSE acct "$USER"; then
-		FAIL "Database contains '$USER'"
-	fi
-	# Add the current user as an admin
-	sqlite3 "${BASEDIR}cokebank.db" "INSERT INTO accounts (acct_name,acct_is_admin,acct_uid) VALUES ('${USER}',1,1);"
-else
-	if $DISPENSE acct accmurph; then
-		FAIL "Database contains 'accmurph' (running as root, might be using prodution)"
-	fi
-fi
+TRY_COMMAND "$DISPENSE acct ${USER}"
+TRY_COMMAND "$DISPENSE pseudo:0"
 
 # Try to add a new user
 TRY_COMMAND "$DISPENSE user add unittest_user0"
diff --git a/tests/_common.sh b/tests/_common.sh
index 04d165702941ed14a410db26ca76ea1a04ab7276..e43a2c8c1611e3558d87f3a6bc2127ae4f9a591d 100644
--- a/tests/_common.sh
+++ b/tests/_common.sh
@@ -25,6 +25,7 @@ coke_dummy_mode yes
 EOF
 
 echo "# AUTOGENERATED Test ${TESTNAME}" > ${BASEDIR}cfg_items.conf
+echo "pseudo	0	0	Test item" >> ${BASEDIR}cfg_items.conf
 
 LOG() {
 	echo "TEST ${TESTNAME}: "$*
@@ -65,3 +66,15 @@ if ! (echo "" | nc localhost ${PORT}); then
 	cat ${BASEDIR}server.log
 	exit 1
 fi
+
+if [[ "x$USER" == "xroot" ]]; then
+	FAIL "Running as root"
+fi
+# Ensure that the database doesn't already contain the current user
+# - 1. Protects against running the test against the production database
+# - 2. Allows adding the current user as an admin
+if $DISPENSE acct "${USER}" 2> /dev/null; then
+	FAIL "Database contains '$USER', are you running on production?"
+fi
+# Add the current user as an admin
+sqlite3 "${BASEDIR}cokebank.db" "INSERT INTO accounts (acct_name,acct_is_admin,acct_uid) VALUES ('${USER}',1,1);"