When I attempt to run \"rake test\" on a local postgres database, it throws the above exception.
Here is my pg_hba.conf file: # Database administrative login by
Change the code as below and it will work
pg_hba.conf:
# IPv4 local connections:
host all all 127.0.0.1/32 trust
# IPv6 local connections:
host all all ::1/128 trust
Below its explanation:
trust
Allow the connection unconditionally. This method allows anyone that can connect to the PostgreSQL database server to login as any PostgreSQL user they wish, without the need for a password or any other authentication.
md5
Require the client to supply a double-MD5-hashed password for authentication.
refer for more here