Class: SimpleCov::ArrayFilter
Instance Attribute Summary
Attributes inherited from Filter
Instance Method Summary collapse
-
#matches?(source_files_list) ⇒ Boolean
Returns true if any of the file paths passed in the given array matches the string configured when initializing this Filter with StringFilter.new([‘some/path’, ‘other/path’]).
Methods inherited from Filter
Constructor Details
This class inherits a constructor from SimpleCov::Filter
Instance Method Details
#matches?(source_files_list) ⇒ Boolean
Returns true if any of the file paths passed in the given array matches the string configured when initializing this Filter with StringFilter.new([‘some/path’, ‘other/path’])
48 49 50 51 52 |
# File 'lib/simplecov/filter.rb', line 48 def matches?(source_files_list) filter_argument.any? do |arg| source_files_list.filename =~ /#{arg}/ end end |