Fork me on GitHub
#announcements
<
2021-07-28
>
mauricio.szabo02:07:55

Just published a new version of my library check (https://gitlab.com/mauricioszabo/check). it's basically a library to allow for better testing - it wraps nubank/matcher-combinators and expectations for matchers, allow the user to define "custom matchers", and have a better support for mocks. It's been battle tested for more than a year, by testing Chlorine, Clover, and multiple projects that I've been working in ClojureScript. But when it really shines, for me, is on asynchronous testing for ClojureScript - it adds the ability to mock async elements, adds a timeout for a test, and teardown. It also does not "fight" against clojure.test, but on the contrary, it embraces it (so tools like kaocha, devcards, workspaces keep working correctly). Discussions on... #testing channel, maybe?

👏 59
🎉 14
3
eggsyntax02:07:45

Looks like a nicely designed hybrid!

seancorfield02:07:45

The syntax reminds me of Midje (unfortunately). I wondered if you had looked at https://github.com/clojure-expectations/clojure-test ?

seancorfield02:07:57

(right now it only works with self-hosted cljs via Planck but I would love to have it work with more general cljs!)

mauricio.szabo03:07:52

There's also a clojure-test-like syntax like:

(check (=> 3 (+ 1 2)))

mauricio.szabo03:07:20

And yes, I looked at this version of expectations and I want to bring its matchers to check. The reason I didn't use it was mostly because I focused this last version on getting the async tests right - that's something that's really weak on ClojureScript IMHO.

3
borkdude11:07:40

Clj-kondo is back with a brand new feature: macroexpansion (and some other improvements) ! https://github.com/clj-kondo/clj-kondo/blob/master/doc/hooks.md#macroexpand This is available in the just released version 2021.07.28! Changelogs: https://github.com/clj-kondo/clj-kondo/blob/master/CHANGELOG.md#20210728 Enjoy. clj-kondo

clj-kondo 127
🚀 35
🎉 23
alexmiller21:07:29

Clojure CLI https://clojure.org/releases/tools#v1.10.3.933 is now available. Changes since last stable release: • deps.edn ◦ https://clojure.org/reference/deps_and_cli#_git • If a git library name follows the repo convention names, the :git/url can now be inferred (`:git/url` can also be specified explicitly and takes precedence) • :git/tag and prefix :git/sha can now be specified instead of the full sha. Both must point to the same commit. ◦ :sha has been renamed to :git/sha but the original is still supported for backwards compatibility ◦ :deps/prep-lib - a new top-level key can be used to say how a source lib should be prepared before being added to the classpath. This key’s value is a map with :alias, :fn, and :ensures. See https://clojure.org/reference/deps_and_cli#prep for more info. ◦ :tools/usage - a new top-level key can be used to provide the :ns-default and :ns-aliases context for a tool • https://clojure.org/reference/deps_and_cli#tool_install - git-based programs that can be installed with a local name. Tools can provide their own usage context in deps.edn. ◦ Added new auto-installed tool named tools with https://clojure.github.io/tools.tools install, list, remove. See https://clojure.org/reference/deps_and_cli#tool_install#. ◦ Install a tool with clojure -Ttools install <lib> <coord> :as <toolname> ◦ Run a tool with clojure -T<toolname> fn (also takes -X style args) • https://clojure.org/reference/deps_and_cli ◦ New -T option is like -X (executes a function) but does not use the project classpath, instead uses tool classpath (and adds :paths ["."] by default). -T:aliases is otherwise same as -X. -Ttoolname resolves named tool by name and uses that tool lib. ◦ https://clojure.atlassian.net/browse/TDEPS-198 - -X and -T will not wait to exit if futures/agents have been used ◦ https://clojure.atlassian.net/browse/TDEPS-182 - Improve deprecation messages to be more accurate ◦ https://clojure.atlassian.net/browse/TDEPS-183 - Fix -Sdescribe output to be valid EDN on Windows ◦ https://clojure.atlassian.net/browse/TDEPS-179 - Fix incorrect classpath when :classpath-overrides removes path ◦ Delay computation of local-repo path (don’t compute at load time) ◦ Use https://github.com/clojure/tools.deps.alpha/blob/master/CHANGELOG.md 0.12.1003 • New -X:deps programs: ◦ find-versions - to find versions of Maven or git libs or tools ◦ prep - use to https://clojure.org/reference/deps_and_cli#prep source libs ◦ help/dir - to list available functions in a tool namespace ◦ help/doc - to list docs for a tool namespace or function

🎉 136
❤️ 39
🚀 29
sheepy 3
🍺 3
orestis06:07:25

Does :git/sha need to be the full one, if :git/tag is present, or could a short one be used (as mentioned in the clojureD presentation?)

alexmiller13:07:45

if both, then short

Michaël Salihi21:07:58

What a great release! Thanks!

alexmiller22:07:04

tools.build {:git/tag "v0.1.7" :git/sha "8a3abc2"} is now available • TBUILD-10 - fix missing assertions in tests • Remove unnecessary resource file that overrides tools.deps

5
👍 27
🛠️ 11
3