Allow passing URI with database to tests (#942)

This commit is contained in:
daurnimator
2017-08-23 19:42:05 -05:00
committed by Joe Nelson
parent 9b5ce3a8af
commit adb3f5c8c0
2 changed files with 5 additions and 4 deletions
+1 -2
View File
@@ -17,8 +17,7 @@ then
fi
BASEPATH=$( cd $(dirname $0) ; pwd -P )
#Remove database path from the connection uri
URI=$(echo $1 | cut -d'/' -f1-3)
URI="$1"
DB=$2
PGOPTIONS='-c client_min_messages=WARNING' psql "$URI" -Xq >/dev/null -c 'select rolcreatedb from pg_authid where rolname = current_user;' 2>/dev/null