rspec/rspec-rails — pull request #764 by pda (2013-06-12 14:21:43+00:00)
Title: stub_model & mock_model handle mock_with syntax = [:expect].

When configured without the `:should` mode present, the `#stub` method is
not available. This means `stub_model` and `mock_model` are broken in this
configuration.

Internal use of a new RSpec::Rails::Mocks.add_stubs method bypasses the
switchable syntax layer, directly configuring a Matchers::Receive instance.

Includes regression test for failure stubbing/mocking models when mock_with is
set to `config.syntax = [:expect]` (no :should option).

See also: rspec/rspec-mocks#306