Method: RSpec::Mocks::ExampleMethods#allow_any_instance_of

Defined in:
lib/rspec/mocks/example_methods.rb

#allow_any_instance_ofObject

Note:

This is only available when you have enabled the expect syntax.

Used to wrap a class in preparation for stubbing a method on instances of it.

Examples:

allow_any_instance_of(MyClass).to receive(:foo)


# File 'lib/rspec/mocks/example_methods.rb', line 327