class method
self.extract_filters
Ruby on Rails 7.0.10
Since v5.2.8.1 PrivateSignature
self.extract_filters(argv)
No documentation comment.
Parameters
-
argvreq
Source
# File railties/lib/rails/test_unit/runner.rb, line 59
def extract_filters(argv)
# Extract absolute and relative paths but skip -n /.*/ regexp filters.
argv.filter_map do |path|
next unless path_argument?(path) && !regexp_filter?(path)
path = path.tr("\\", "/")
case
when /(:\d+)+$/.match?(path)
file, *lines = path.split(":")
filters << [ file, lines ]
file
when Dir.exist?(path)
"#{path}/**/*_test.rb"
else
filters << [ path, [] ]
path
end
end
end
Defined in railties/lib/rails/test_unit/runner.rb line 59
· View on GitHub
· Improve this page
· Find usages on GitHub
Defined in Rails::TestUnit::Runner