Sha256: e063910a78ecc3020a56eb6bdf7bef20ad40716dc1f1976be7d6bf063291aefc

Contents?: true

Size: 297 Bytes

Versions: 30

Compression:

Stored size: 297 Bytes

Contents

module Gherkin
  module Formatter
    class RegexpFilter
      def initialize(regexen)
        @regexen = regexen
      end

      def eval(names)
        @regexen.detect do |regexp| 
          names.detect do |name|
            name =~ regexp
          end
        end
      end
    end
  end
end

Version data entries

30 entries across 30 versions & 1 rubygems

Version Path
gherkin-2.1.5 lib/gherkin/formatter/regexp_filter.rb
gherkin-2.1.5-i386-mswin32 lib/gherkin/formatter/regexp_filter.rb
gherkin-2.1.5-i386-mingw32 lib/gherkin/formatter/regexp_filter.rb
gherkin-2.1.5-universal-dotnet lib/gherkin/formatter/regexp_filter.rb
gherkin-2.1.5-java lib/gherkin/formatter/regexp_filter.rb
gherkin-2.1.4 lib/gherkin/formatter/regexp_filter.rb
gherkin-2.1.4-i386-mswin32 lib/gherkin/formatter/regexp_filter.rb
gherkin-2.1.4-i386-mingw32 lib/gherkin/formatter/regexp_filter.rb
gherkin-2.1.4-universal-dotnet lib/gherkin/formatter/regexp_filter.rb
gherkin-2.1.4-java lib/gherkin/formatter/regexp_filter.rb
gherkin-2.1.3 lib/gherkin/formatter/regexp_filter.rb
gherkin-2.1.3-i386-mswin32 lib/gherkin/formatter/regexp_filter.rb
gherkin-2.1.3-i386-mingw32 lib/gherkin/formatter/regexp_filter.rb
gherkin-2.1.3-universal-dotnet lib/gherkin/formatter/regexp_filter.rb
gherkin-2.1.3-java lib/gherkin/formatter/regexp_filter.rb
gherkin-2.1.2 lib/gherkin/formatter/regexp_filter.rb
gherkin-2.1.2-i386-mswin32 lib/gherkin/formatter/regexp_filter.rb
gherkin-2.1.2-i386-mingw32 lib/gherkin/formatter/regexp_filter.rb
gherkin-2.1.2-universal-dotnet lib/gherkin/formatter/regexp_filter.rb
gherkin-2.1.2-java lib/gherkin/formatter/regexp_filter.rb