This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2017-12-26
Channels
- # adventofcode (12)
- # beginners (141)
- # cider (3)
- # cljsrn (3)
- # clojure (76)
- # clojure-russia (1)
- # clojure-spec (7)
- # clojure-uk (4)
- # clojurescript (15)
- # css (1)
- # duct (3)
- # emacs (5)
- # fulcro (85)
- # keechma (1)
- # leiningen (44)
- # off-topic (29)
- # om (6)
- # parinfer (4)
- # perun (1)
- # re-frame (18)
- # reagent (2)
- # ring-swagger (8)
- # shadow-cljs (5)
- # spacemacs (1)
- # sql (7)
Hello, while trying to use compojure-api, I have a question about exactly how to use this. In readme there is some examples,
I assumed these are interchangeable alternatives. I want to use the data-driven approach (the first one). but there is no "path" (like "/hello-async") in the second example. I'd like an example with data-driven approach where a path is included, if possible please 🙂
Thank you in advance!
I found how to add paths in data-driven way 🙂 they had to be nested in context
as in https://github.com/metosin/compojure-api/blob/master/examples/resources/src/example/handler.clj
Hi, I was testing a Get endpoint made with compojure-api with Midje & Ring mock. I found something weird.
Here I am expecting JSON in :body
but I am getting inputstream. Also :compojure.api.meta/serializable? true
part is not something I am expecting... Though when I make http calls with POSTMAN(curl substitute) then I get expected response. Is this expected behavior?
I would like to know how do you test endpoints by compojure-api in real world applications...
about inputstream in body, I forgot that I had to slurp (because with techstack I use in my company, the body is already string without slurp, so I never had to slurp the body in tests). Now that I slurp and parse-string
the body is as expected. but still I wonder what's the purpose of :compojure.api.meta/serializable? true