I will answer the clojure.test question, since I wrote it. You can call clojure.test/is with *any* Clojure expression: if the expression returns logical true, the assertion passes. Having just the one expression keeps the scope of the testing library small.
The `clojure.test/is` macro was designed to be extensible, based on the syntax of the expression you pass it, but in a really convoluted way involving multimethods and macroexpansion. It was an experiment that did not turn out well, and I don't recommend it. –Stuart S. On Wednesday, September 28, 2016 at 10:31:37 AM UTC-4, paul wrote: > > The second is smaller, but is more a question. clojure.test seems to only > have 'is' so for things like equality I end up writing (is (= (...) (...))) > a lot. Or to test if an exception is thrown (is (thrown? ...)). That's OK, > but I'm wondering what led to that decision rather than having is-eq and > is-thrown and so on (considering the core language has shortcuts like when > and unless and if-not so the compound macros seem idiomatic). > -- You received this message because you are subscribed to the Google Groups "Clojure" group. To post to this group, send email to clojure@googlegroups.com Note that posts from new members are moderated - please be patient with your first post. To unsubscribe from this group, send email to clojure+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/clojure?hl=en --- You received this message because you are subscribed to the Google Groups "Clojure" group. To unsubscribe from this group and stop receiving emails from it, send an email to clojure+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout.