method

remove_stub

Importance_0
remove_stub(message) public

No documentation

This method has no description. You can help the RSpec community by adding new notes.

Hide source
# File lib/spec/mocks/proxy.rb, line 68
      def remove_stub(message)
        message = message.to_sym
        if stub_to_remove = @stubs.detect { |s| s.matches_name?(message) }
          reset_proxied_method(message)
          @stubs.delete(stub_to_remove)
        else
          raise MockExpectationError, "The method `#{message}` was not stubbed or was already unstubbed"
        end
      end
Register or log in to add new notes.