This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2022-08-18
Channels
- # announcements (17)
- # babashka (42)
- # beginners (34)
- # calva (78)
- # cherry (1)
- # cider (7)
- # clojure (64)
- # clojure-europe (19)
- # clojure-nl (2)
- # clojure-norway (54)
- # clojure-uk (3)
- # clojurescript (21)
- # cloverage (1)
- # conjure (1)
- # core-async (11)
- # cryogen (16)
- # cursive (1)
- # data-oriented-programming (1)
- # datahike (5)
- # fulcro (2)
- # girouette (1)
- # helix (10)
- # hyperfiddle (1)
- # jobs (1)
- # kaocha (4)
- # nbb (7)
- # off-topic (6)
- # pathom (4)
- # polylith (21)
- # rdf (9)
- # releases (2)
- # shadow-cljs (3)
- # sql (12)
- # squint (68)
- # vim (33)
- # xtdb (29)
What is a good way to test with pathom? I’m thinking using resolvers that return dummy data or generated data, and then test queries against that. Or, is there a better way to inject testing facilities?
You can call resolvers as regular functions and test them as you would normal functions. https://pathom3.wsscode.com/docs/resolvers/#invoking-resolvers
for isolated tests calling the resolvers directly is a good way to go
I personally prefer more integration style tests, so you can emulate the situations your app needs, going over the whole pathom process thing
1