rspec/rspec-mocks — pull request #256 by jferris (2013-03-29 17:48:14+00:00)
Title: Generate a useful description for have_received

* Makes `it { should have_received(:message) }` produce useful output

Resolves #254.

A few implementation notes:

* I added the actual description to ErrorGenerator, as it has a lot of useful, reusable behavior related to messages. However, it's not a message, so maybe it should go somewhere else, or that class should be renamed to "MessageGenerator"?
* I separated `Proxy#build_expectation` into two phases so that exceptions won't be raised when calling `matches?` or `description`. Otherwise, you don't get a description if you mess up the stub.