This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2022-07-13
Channels
- # aleph (15)
- # announcements (4)
- # babashka (36)
- # babashka-sci-dev (1)
- # beginners (15)
- # biff (2)
- # calva (15)
- # cider (3)
- # clj-kondo (8)
- # clojure (149)
- # clojure-europe (14)
- # clojure-norway (13)
- # clojure-switzerland (1)
- # clojure-uk (1)
- # clojurescript (21)
- # community-development (5)
- # cursive (20)
- # data-science (2)
- # datomic (7)
- # duct (5)
- # emacs (19)
- # etaoin (3)
- # events (2)
- # fulcro (11)
- # introduce-yourself (2)
- # jobs (4)
- # jobs-discuss (19)
- # joyride (1)
- # leiningen (11)
- # malli (7)
- # membrane (131)
- # nbb (12)
- # nginx (1)
- # off-topic (33)
- # pathom (8)
- # polylith (28)
- # re-frame (8)
- # sci (7)
- # shadow-cljs (225)
- # spacemacs (10)
- # specter (1)
- # vim (10)
- # xtdb (8)
Hi imre! I’m trying to use polylith-kaocha and am I right that some hooks like pre|post-test|load(etc)
don’t support yet? I’ve looked up the source code and found nothing about it.
cuz I want to do integration tests and need some hooks!
yeah, I mean Kaocha hooks
That already works but I think I’m confused with hooks in kaocha config and https://github.com/imrekoszo/polylith-kaocha#hooking-into-parts-of-the-process one.
Then, all I just have to do is make hooks in kaocha config?
Ok cool! great! wanna ask one more thing!
clojure -Srepro -M:poly test project:my-project
I do test my-project including serveral bricks (bases/components) including also have tests.
In that case, how hooks in kaocha config placed in my-project work?tests.edn in my-project and I imagined that every bricks are hooked pre-test
Ahh, do you consider my requirement is needed in the future?
just curious
at the same time, that’s not a good use case cuz polylith suggest that integ test would be in a project, not in bricks. That means, in general, we wouldn’t need hooks in bricks?
I’m not sure. Polylith doesn’t have per-brick test setup/teardown. I haven’t had the need to have that. Integration tests should IMO operate at the project level
If this presents a difficulty, you could add a https://github.com/imrekoszo/polylith-kaocha/blob/182e88dfb3aebcc4be321130fd7d0e6e77beafc6/bases/example/test/polylith_kaocha/example/hooks.clj#L19 and invoke kaocha in a different way, i.e. per brick somehow
I saw there is a fork of polylith-kaocha that adds support for https://github.com/imrekoszo/polylith-kaocha/compare/master...SavageMessiah:polylith-kaocha:exclude-bricks?w=true, not sure if that is something that would help you
You could also create an issue in the repo so a potential feature could be discussed and specified
Thanks for your comment. I’ll figure out my test structure and needs. 🙂