ring-swagger

ring-swagger & compojure-api
ikitommi 2018-10-19T08:35:31.000100Z

@piotr2b hi. ring-mock send the body as form-encoded, you need to write the json-body yourself.

ikitommi 2018-10-19T08:35:36.000100Z

(-> (assoc (mock/request :post "/application/path/endpoint" (cheshire.core/generate-string {:a 7}))
      :content-type "application/json")
    (app)
    :body
    (slurp)
    (cheshire/parse-string true))

ikitommi 2018-10-19T08:35:52.000100Z

works for the first example

ikitommi 2018-10-19T08:38:37.000100Z

@mping 2.0.0 uses Jsonista, which takes the encoders as explicit configuration options :encoders. The docs aren’t great, but are here: https://cljdoc.xyz/d/metosin/jsonista/0.2.2/api/jsonista

2018-10-19T09:00:49.000100Z

@ikitommi tks, will take a look