Add the ability to temporarily turn off `verify_partial_doubles`
Created by: penelopezone
In https://github.com/rspec/rspec-rails/issues/1076 and https://github.com/rspec/rspec-rails/issues/1219 we encountered some issues with partial mocks and view specs. We should add the ability to temporarily disable verify_partial_doubles
.
The implementation signature could potentially look like without_verifying_partial_doubles(&blk)
such that
around do |ex|
without_verifying_partial_doubles { ex.run }
end
and
it "does something weird with mocks" do
without_verifying_partial_doubles do
...
end
end
The implementation strategy for this would simply set/reset the values in RSpec Mocks' configuration which are found here
I'm happy to mentor on this one if someone needs help