improved output schema
This commit is contained in:
parent
7097edcc77
commit
f3c486a733
1 changed files with 7 additions and 3 deletions
|
@ -27,14 +27,18 @@
|
|||
(def ^:dynamic
|
||||
*target-dir* "target/datatest/")
|
||||
|
||||
;TODO: replace schema with spec
|
||||
(def TestDataReport
|
||||
{:test-event s/Any
|
||||
:test-data-spec s/Any})
|
||||
|
||||
(s/defn write-data-test-output
|
||||
[m]
|
||||
(let [data-spec-file (loader/data-spec-file *data-test-report-context*)
|
||||
output-file (str *target-dir* data-spec-file)]
|
||||
(io/make-parents output-file)
|
||||
(spit output-file (merge
|
||||
{:test-event m}
|
||||
*data-test-report-context*))))
|
||||
(spit output-file {:test-event m
|
||||
:test-data-spec *data-test-report-context*})))
|
||||
|
||||
(defmethod t/report :default [m]
|
||||
(t/with-test-out (prn m)))
|
||||
|
|
Loading…
Reference in a new issue