on_stubbing_method_on_non_mock_object (Mocha::Mockery)

         # File lib/mocha/mockery.rb, line 124
    124:     def on_stubbing_method_on_non_mock_object(object, method)
    125:       if Mocha::Configuration.prevent?(:stubbing_method_on_non_mock_object)
    126:         raise StubbingError.new("stubbing method on non-mock object: #{object.mocha_inspect}.#{method}", caller)
    127:       end
    128:       if Mocha::Configuration.warn_when?(:stubbing_method_on_non_mock_object)
    129:         logger.warn "stubbing method on non-mock object: #{object.mocha_inspect}.#{method}"
    130:       end
    131:     end