This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2016-07-24
Channels
- # admin-announcements (2)
- # beginners (5)
- # boot (29)
- # cider (46)
- # cljsjs (1)
- # clojure (19)
- # clojure-quebec (1)
- # clojure-russia (73)
- # clojure-spec (30)
- # clojure-uk (23)
- # clojurescript (35)
- # datascript (12)
- # datomic (7)
- # emacs (26)
- # hoplon (168)
- # leiningen (7)
- # off-topic (2)
- # om (32)
- # perun (8)
- # protorepl (8)
- # ring (45)
- # specter (10)
- # test-check (2)
- # yada (6)
I would exclude that (95%) as I am using boot with-cp -s
exatly to avoid that...it looks like it is more of a ex-info
problem though, because I am not sure clojure.logging
knows how to print an ex-info, I am actually going to check the source, it is better than guessing 😄
looks like there is nothing preventing it to print it out: https://github.com/clojure/clojure/blob/d5708425995e8c83157ad49007ec2f8f43d8eac8/src/jvm/clojure/lang/ExceptionInfo.java#L40
@richiardiandrea: It's likely not caused by anything in clojure.tools.logging
but rather the underlying logging implementation and how it prints exceptions. Some logging implementations (java.util.logging for example) will print Exceptions by calling .toString()
; some (Logback for example) use .getMessage()
instead.
@stuartsierra: thanks for sharing, I think this is the missing piece, I am using Log4j2 at the moment and I saw that Clojure.logging as you said just retrieves the logger instance
So I guess it is not calling toString for ERROR
Hey all. Having spent some time yak shaving with Cucumber testing clojure apps, it would appear that it’s so low-used within our community that I might be better investigating other libraries / frameworks / approaches that support acceptance / integration testing. What do you use?
@paulspencerwilliams, a lot of people just stick with the official clojure.test
. It’s battle-tested, hardy, and decidedly less fancy than the alternatives. I personally really like Jay Fields’ Expectations because it’s highly flexible and deliciously minimalist. And people tend to have a love-it-or-hate-it opinion on Midje.
I do everything in clojure.test
these day mainly because it’s mostly widely adopted and it does get out of my way.
yeah, I don’t want to invest time in learning another testing framework. clojure.test is simple enough and does the job. I have testing framwork fatigue and js tooling fatigue 🙂
So plain clojure.test tests with abstractions of the web UI, and database connectivity for clean up etc?
Sorry, so cleaning up app state after each test run for the next test.
Honestly, if I’m testing, I do it all in isolation. Once you involve a database or whatever, you’re not unit testing anymore, it’s integration.
@akiva: agreed, I do most testing with isolation, but I've always relied on a set of integration tests to ensure all the units work together.
In this component example, there’s a dummy message broker. https://github.com/stuartsierra/component/blob/master/dev/user.clj How would you actually implement this message broker?