Sha256: b571880bf69ba63e552f54c8ea1522fd100f673a537ba02940b51ab9a5224e74

Contents?: true

Size: 349 Bytes

Versions: 38

Compression:

Stored size: 349 Bytes

Contents

module Mocha
  class MethodMatcher
    attr_reader :expected_method_name

    def initialize(expected_method_name)
      @expected_method_name = expected_method_name
    end

    def match?(actual_method_name)
      @expected_method_name == actual_method_name.to_sym
    end

    def mocha_inspect
      @expected_method_name.to_s
    end
  end
end

Version data entries

38 entries across 38 versions & 3 rubygems

Version Path
mocha-2.6.0 lib/mocha/method_matcher.rb
mocha-2.5.0 lib/mocha/method_matcher.rb
mocha-2.4.5 lib/mocha/method_matcher.rb
mocha-2.4.4 lib/mocha/method_matcher.rb
mocha-2.4.3 lib/mocha/method_matcher.rb
mocha-2.4.2 lib/mocha/method_matcher.rb
mocha-2.4.1 lib/mocha/method_matcher.rb
mocha-2.4.0 lib/mocha/method_matcher.rb
mocha-2.2.0 lib/mocha/method_matcher.rb
mocha-2.1.0 lib/mocha/method_matcher.rb
mocha-2.0.4 lib/mocha/method_matcher.rb
mocha-2.0.3 lib/mocha/method_matcher.rb
fluent-plugin-google-cloud-logging-on-prem-0.1.0 vendor/ruby/3.1.0/gems/mocha-2.0.2/lib/mocha/method_matcher.rb
mocha-2.0.2 lib/mocha/method_matcher.rb
mocha-1.16.1 lib/mocha/method_matcher.rb
mocha-1.15.1 lib/mocha/method_matcher.rb
mocha-2.0.1 lib/mocha/method_matcher.rb
mocha-2.0.0 lib/mocha/method_matcher.rb
mocha-1.16.0 lib/mocha/method_matcher.rb
mocha-2.0.0.alpha.1 lib/mocha/method_matcher.rb