Skip to content
Snippets Groups Projects
Commit 4e5aefb6 authored by Cam Saül's avatar Cam Saül
Browse files

Fix MySQL & Postgres tests on localhost w/o password [ci drivers]

parent 4e778936
No related branches found
No related tags found
No related merge requests found
......@@ -21,8 +21,9 @@
(merge {:host (i/db-test-env-var-or-throw :mysql :host "localhost")
:port (i/db-test-env-var-or-throw :mysql :port 3306)
:user (i/db-test-env-var :mysql :user "root")
:password (i/db-test-env-var :mysql :password)
:timezone :America/Los_Angeles}
(when-let [password (i/db-test-env-var :mysql :password)]
{:password password})
(when (= context :db)
{:db database-name})))
......
......@@ -22,9 +22,11 @@
(defn- database->connection-details [context {:keys [database-name]}]
(merge {:host (i/db-test-env-var-or-throw :postgresql :host "localhost")
:port (i/db-test-env-var-or-throw :postgresql :port 5432)
:user (i/db-test-env-var :postgresql :user)
:password (i/db-test-env-var :postgresql :password)
:timezone :America/Los_Angeles}
(when-let [user (i/db-test-env-var :postgresql :user)]
{:user user})
(when-let [password (i/db-test-env-var :postgresql :password)]
{:password password})
(when (= context :db)
{:db database-name})))
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment