Sha256: 1a9443c8aef9db09993fb0e6030ae3650aa318cc794f4e3fdb283a034be07ee4

Contents?: true

Size: 397 Bytes

Versions: 8

Compression:

Stored size: 397 Bytes

Contents

module Mutest
  class Matcher
    # Matcher filter
    class Filter < self
      include Concord.new(:matcher, :predicate)

      # Enumerate matches
      #
      # @param [Env::Bootstrap] env
      #
      # @return [Enumerable<Subject>]
      def call(env)
        matcher
          .call(env)
          .select(&predicate.method(:call))
      end
    end # Filter
  end # Matcher
end # Mutest

Version data entries

8 entries across 8 versions & 1 rubygems

Version Path
mutest-0.0.9 lib/mutest/matcher/filter.rb
mutest-0.0.8 lib/mutest/matcher/filter.rb
mutest-0.0.7 lib/mutest/matcher/filter.rb
mutest-0.0.6 lib/mutest/matcher/filter.rb
mutest-0.0.5 lib/mutest/matcher/filter.rb
mutest-0.0.4 lib/mutest/matcher/filter.rb
mutest-0.0.3 lib/mutest/matcher/filter.rb
mutest-0.0.2 lib/mutest/matcher/filter.rb