This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2019-02-08
Channels
- # announcements (2)
- # aws (1)
- # beginners (134)
- # calva (26)
- # cider (48)
- # cljdoc (41)
- # cljs-dev (12)
- # clojure (178)
- # clojure-brasil (1)
- # clojure-europe (16)
- # clojure-italy (30)
- # clojure-nl (13)
- # clojure-spec (118)
- # clojure-uk (81)
- # clojurescript (209)
- # community-development (77)
- # cursive (7)
- # datomic (23)
- # duct (6)
- # emacs (15)
- # events (2)
- # figwheel (13)
- # figwheel-main (18)
- # fulcro (4)
- # jackdaw (4)
- # jobs (6)
- # jobs-discuss (6)
- # kaocha (2)
- # lein-figwheel (3)
- # off-topic (4)
- # other-languages (22)
- # pathom (2)
- # pedestal (9)
- # perun (10)
- # portkey (1)
- # re-frame (41)
- # reagent (6)
- # reitit (4)
- # remote-jobs (1)
- # ring-swagger (6)
- # rum (5)
- # shadow-cljs (300)
- # sql (3)
- # test-check (6)
- # testing (7)
- # vim (1)
- # yada (9)
You have one function that is doing too much.
Test each individual function. Then test the orchestration function end-to-end as a black box instead of testing that makes specific calls to implementation functions.
So I am testing the individual functions that I have stubbed out here (`extract-userintent-from-s3`, etc.) elsewhere. This is an attempt to test the orchestration function extract-transform-and-load-xxx
.
Like I say, test end-to-end or don't bother testing. The orchestration function should be so simple it's "correct by inspection" and, if not, refactor it to be so.
If writing tests for something is painful, then either the code is too complex or the test is not worth doing.
You're also introducing a lot of coupling in your tests which will make them brittle.