23 lines
796 B
Common Lisp
23 lines
796 B
Common Lisp
;;; cl-scopes/test/config-postgres.lisp
|
|
;;; use: `(load "test/...")` from package scopes/test-storage
|
|
|
|
(in-package :scopes/test-storage)
|
|
|
|
(config:root :env-keys '(:db-name :db-user :db-password))
|
|
|
|
(config:add :logger :class 'logging:config
|
|
:loglevel :info
|
|
:logfile (t:test-path "scopes-test.log" "log")
|
|
:console nil)
|
|
|
|
(defvar postgres-connect-args
|
|
(list :database-name (config:from-env :db-name "cltest")
|
|
:host "localhost"
|
|
:port 5432
|
|
:username (config:from-env :db-user "testuser")
|
|
:password (config:from-env :db-password "secret")))
|
|
|
|
(config:add :storage :class 'storage:config :setup #'storage:setup
|
|
:db-type :postgres
|
|
:connect-args postgres-connect-args
|
|
:options '(:schema "testing"))
|