This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2020-05-23
Channels
- # announcements (5)
- # aws (9)
- # babashka (60)
- # beginners (561)
- # calva (8)
- # cider (17)
- # clj-kondo (1)
- # cljsrn (12)
- # clojure (36)
- # clojure-dev (3)
- # clojure-europe (3)
- # clojure-france (10)
- # clojure-greece (8)
- # clojure-italy (6)
- # clojure-spec (3)
- # clojure-uk (6)
- # clojurescript (30)
- # community-development (2)
- # conjure (15)
- # datascript (24)
- # figwheel-main (49)
- # fulcro (29)
- # helix (72)
- # off-topic (20)
- # pathom (7)
- # rum (7)
- # shadow-cljs (23)
- # spacemacs (6)
- # sql (8)
- # timbre (1)
- # xtdb (10)
can someone tell me what command is being run to start cider in this video at this point? https://youtu.be/9sVGy0IovH8?t=1471
For integration tests that needs external services to be turned on, for instance a DB, would you simply write a script that starts the service and then runs the test or is there another way to do it? Assume this is simply with deps and no Leiningen etc
@srijayanth Depends on the DB. Which one are you using?
redis, but Mongo will soon follow
Hmm, I'd probably use Docker locally to spin up test instances -- and do that as a separate step prior to running tests with <insert your favorite Clojure tool>
We use Redis at work and used to use MongoDB. We use docker-compose up
to stand up instances of Redis, Percona (MySQL), and ElasticSearch now. Used to also stand up MongoDB too.
We just have a permanent development DB running, and use that for integ tests. Not very fancy and you pay when you don't use it. But it's the smallest instance and simple enough.
If you were using PostgreSQL, I'd suggest looking at the embedded (Java) version -- which is what I use for testing next.jdbc
@didibus A shared DB system? How do you manage individual standup and teardown of data around tests?
How does that work when you're testing code that has to assume certain tables and relationships?
@seancorfield - ok, that makes sense.
I wouldn't call it great. Just straightforward I guess. Create the tables you want, insert some documents, test, delete.
There's definitely a lot of tests sharing the same tables as well, that just clean up the documents they created
And there's definitely some test that don't even clean up properly and leave crap behind them if I'm being real honest 😝
I can't remember, are you allowed to use the Clojure logo say in a blog post? Or as part of a tutorial guide?
i notice a large amount of throwables getting generated when profiling but i can't catch them anywhere
Is my understanding correct that (def a@ 1)
is actually read as (def a (deref 1))
and hence invalid?
> '(def a@ 1)
(def a (clojure.core/deref 1))
fwiw I'd say @
is simply read, not macroexpanded$ plk
ClojureScript 1.10.597
cljs.user=> (binding [*print-meta* true] (print-str ^{:a 1} []))
"^{:a 1} []"