Provide a callback before returning default mocks as values
When you set up a Mock with DefaultValue.Mock it will return mock instances for any members that don't have Setups defined.
I'm doing a lot of work with AutoMocking containers, and in that scenario it would be really nice to have a callback that would allow me to intercept this behavior.
My AutoMocking container will take care of returning a mock of IFoo, and with DefaultValue.Mock, a member will automatically return a mock of IBar.
However, I would really like to be able to say that "whenever Moq tries to return IBaz from an IBar method, I want to be able to intercept this and replace the return value with something I explicitly define."
This might be a callback or an interface we can register on a Mock or MockFactory, or perhaps an event...
yes, we had a request to allow the default value strategy be open (it’s already pluggable internally)