Closed glenjamin closed 9 years ago
This doesn't seem significantly more useful that (with-redefs [foo (constantly 1)]). What's the usecase?
It's equivalent to with-redefs followed by with with-spy - but just reduces clutter in tests a bit.
@glenjamin looks like the target branch has changed significantly from the original PR description. Feel free to re-open if you want me to look at this again.
No worries, I ended up doing a friendly fork - didn't even realise this was still open!
Are you still using bond
much internally?
Are you still using bond much internally?
Yup, a lot of our unit tests use it. I find it great for cases where it would be a lot of work to inject a dependency.
As discussed on IRC, I'm pretty new to clojure so I may have screwed up the style.
I've added test-cases, and hopefully managed to keep this pretty tidy.