on_stubbing_non_public_method (Mocha::Mockery)

         # File lib/mocha/mockery.rb, line 115
    115:     def on_stubbing_non_public_method(object, method)
    116:       if Mocha::Configuration.prevent?(:stubbing_non_public_method)
    117:         raise StubbingError.new("stubbing non-public method: #{object.mocha_inspect}.#{method}", caller)
    118:       end
    119:       if Mocha::Configuration.warn_when?(:stubbing_non_public_method)
    120:         logger.warn "stubbing non-public method: #{object.mocha_inspect}.#{method}"
    121:       end
    122:     end