What action do you want to perform
Use postgresql in detached mode on a standard pg account and database:
createuser pytest # with password "pytest"
createdb -O pytest pytest
pytest --postgresql-detached --postgresql-user=pytest --postgresql-password=pytest --postgreqsl-dbname=pytest ...
What are the results
The connection fails because it attempts to connect to the postgres database.
This is hardcoded here.
What are the expected results
It should use the provided dbname to get the version, and succeed.