Sha256: dc6b872fa0730aea3dc1a56c2ed0d8dc43b0465cabcad7b6b674a7d41105cb19

Contents?: true

Size: 477 Bytes

Versions: 17

Compression:

Stored size: 477 Bytes

Contents

# encoding: utf-8

module Mutant
  class Matcher
    # A null matcher, that does not match any subjects
    class Null < self
      include Equalizer.new

      # Enumerate subjects
      #
      # @return [Enumerator<Subject]
      #   if no block given
      #
      # @return [self]
      #   otherwise
      #
      # @api private
      #
      def each(&block)
        return to_enum unless block_given?
        self
      end

    end # Null
  end # Matcher
end # Mutant

Version data entries

17 entries across 17 versions & 1 rubygems

Version Path
mutant-0.5.16 lib/mutant/matcher/null.rb
mutant-0.5.15 lib/mutant/matcher/null.rb
mutant-0.5.14 lib/mutant/matcher/null.rb
mutant-0.5.13 lib/mutant/matcher/null.rb
mutant-0.5.12 lib/mutant/matcher/null.rb
mutant-0.5.11 lib/mutant/matcher/null.rb
mutant-0.5.10 lib/mutant/matcher/null.rb
mutant-0.5.9 lib/mutant/matcher/null.rb
mutant-0.5.8 lib/mutant/matcher/null.rb
mutant-0.5.7 lib/mutant/matcher/null.rb
mutant-0.5.6 lib/mutant/matcher/null.rb
mutant-0.5.5 lib/mutant/matcher/null.rb
mutant-0.5.4 lib/mutant/matcher/null.rb
mutant-0.5.3 lib/mutant/matcher/null.rb
mutant-0.5.2 lib/mutant/matcher/null.rb
mutant-0.5.1 lib/mutant/matcher/null.rb
mutant-0.5.0 lib/mutant/matcher/null.rb