From: John Hodge Date: Sun, 19 Sep 2021 07:13:05 +0000 (+0800) Subject: Tests - Tweak to the running-as-root check X-Git-Url: https://git.ucc.asn.au/?p=tpg%2Fopendispense2.git;a=commitdiff_plain;h=067245e37fea88320ad8b431b4410ae384fc1f32 Tests - Tweak to the running-as-root check --- diff --git a/tests/TEST_basic.sh b/tests/TEST_basic.sh index 76c6490..d128f8d 100755 --- a/tests/TEST_basic.sh +++ b/tests/TEST_basic.sh @@ -5,7 +5,7 @@ TESTNAME=basic . _common.sh # (CI runs as root, and root is auto-added by databse creation) -if [[ "$USER" -ne "root" ]]; then +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