Sha256: 7761e74ed531133ea7fbd370f2ef4474c815b795b31a143d5db1adf9a92991ff

Contents?: true

Size: 610 Bytes

Versions: 4

Compression:

Stored size: 610 Bytes

Contents

module DevelopWithPassion
  module Fakes
    module RSpec
      class Occurances
        class << self
          def from_block(the_block)
            return BlockCriteria.new(the_block)
          end
          def exact(times)
            return from_block(lambda{|occurances| return occurances == times})
          end
          def at_least(times)
            return from_block(lambda { |occurences| return occurences >= times})
          end
          def at_most(times)
            return from_block(lambda { |occurences| return occurences <= times})
          end
        end
      end
    end
  end
end

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
developwithpassion_fakes-rspec-0.0.8 lib/core/occurances.rb
developwithpassion_fakes-rspec-0.0.7 lib/core/occurances.rb
developwithpassion_fakes-rspec-0.0.6 lib/core/occurances.rb
developwithpassion_fakes-rspec-0.0.5 lib/core/occurances.rb