Sha256: d0116501c00f16f7190f0926ec766964b51ef1f9ae0d3db83501e5de961a0067

Contents?: true

Size: 306 Bytes

Versions: 7

Compression:

Stored size: 306 Bytes

Contents

module RR
module TimesCalledMatchers
  class IntegerMatcher < TimesCalledMatcher
    def possible_match?(times_called)
      times_called <= @times
    end

    def matches?(times_called)
      times_called == @times
    end

    def attempt?(times_called)
      times_called < @times
    end
  end
end
end

Version data entries

7 entries across 7 versions & 1 rubygems

Version Path
rr-0.1.13 lib/rr/times_called_matchers/integer_matcher.rb
rr-0.1.10 lib/rr/times_called_matchers/integer_matcher.rb
rr-0.1.8 lib/rr/times_called_matchers/integer_matcher.rb
rr-0.1.11 lib/rr/times_called_matchers/integer_matcher.rb
rr-0.1.7 lib/rr/times_called_matchers/integer_matcher.rb
rr-0.1.12 lib/rr/times_called_matchers/integer_matcher.rb
rr-0.1.9 lib/rr/times_called_matchers/integer_matcher.rb