Re: Stubbing with instrument and generators

2017-06-30 Thread Michael Glaesemann
Thanks for taking a look. Here's a ticket: https://dev.clojure.org/jira/browse/CLJ-2197 > On 2017-06-30, at 11:52, Alex Miller wrote: > > I don't think this is the same case as CLJ-2095 as the instrumented var > should have the opportunity to use the gen overrides you've included. In > partic

Re: Stubbing with instrument and generators

2017-06-30 Thread Alex Miller
I don't think this is the same case as CLJ-2095 as the instrumented var should have the opportunity to use the gen overrides you've included. In particular, it seems like stest/instrument-choose-fn is currently passing the :gen overrides map when getting the gen for the stubbed var. I'm wonderi

Stubbing with instrument and generators

2017-06-30 Thread Michael Glaesemann
Using spec instrument to stub functions is really helpful. I'm using stubbing to test Stuart Sierra-style components with some success. However, I've been surprised that generator override doesn't work as I would expect it to. Here's an example: ;; [org.clojure/spec.alpha "0.1.123"] (require '