class Mocha::ParameterMatchers::RespondsWith
Parameter matcher which matches if actual parameter returns expected result when specified method is invoked.
def initialize(message, result)
- Private: -
def initialize(message, result) @message = message @result = result end
def matches?(available_parameters)
- Private: -
def matches?(available_parameters) parameter = available_parameters.shift @result.to_matcher.matches?([parameter.__send__(@message)]) end
def mocha_inspect
- Private: -
def mocha_inspect "responds_with(#{@message.mocha_inspect}, #{@result.mocha_inspect})" end