freerange / mocha

A mocking and stubbing library for Ruby
https://mocha.jamesmead.org
Other
1.23k stars 158 forks source link

Better error message if `Mockery.teardown` is called when `Mockery.setup` has not been called successfully #646

Open floehopper opened 6 months ago

floehopper commented 6 months ago

This seems to have happened to at least a couple of people in relation to Rails fixtures - see #611. I think we could probably provide a more useful error message if Mockery.instance is not set.