mirror of
https://github.com/unclebob/more-speech.git
synced 2024-09-30 02:21:02 +00:00
15 lines
471 B
Clojure
15 lines
471 B
Clojure
(ns more-speech.spec-util
|
|
(:require
|
|
[more-speech.config :as config]
|
|
[more-speech.db.in-memory :as in-memory]
|
|
[more-speech.mem :as mem]
|
|
[speclj.core :refer :all]))
|
|
|
|
(defmacro setup-db-mem []
|
|
`(list (with ~'db (in-memory/get-db))
|
|
(before-all (config/set-db! :in-memory))
|
|
(before (in-memory/clear-db @~'db)
|
|
(mem/clear-mem))))
|
|
|
|
;the list forces the execution of the three statements.
|
|
;(prn (macroexpand '(setup-db-mem))) |