Open oz123 opened 4 years ago
Yeah, what's funny is I had a sample test in there that just called app
and checked for a success response but I took it out.
Not sure why now that I think about it.
It's time to put it back in though, I agree
A few more suggestions:
Add a JSON API end point to the routes (in main.janet
):
(defn api [request]
(application/json {:you-found "joy"})
)
...
(def routes (routes [:get "/" home] [:get "/api" api]))
@swlkr I figured out how to use http (it's pretty awesome that this is simply syntactic sugar on top of curl). Would like me to send a PR with my suggestions?
Yeah! Open up a PR and we can get it merged
First, let me say thanks! I just started with joy and it is a joy! I saw you also created a nice testing framework. How about adding a simple test case to the default template to encourage people to write tests and also demonstrate the framework?