Class: Rails::TestUnit::Filter
Do not use. This class is for internal use only.
Relationships & Source Files | |
Inherits: | Object |
Defined in: | railties/lib/rails/test_unit/runner.rb |
Class Method Summary
- .new(runnable, file, line_or_range) ⇒ Filter constructor
Instance Method Summary
- #===(method)
- #definition_for(method) private
Constructor Details
.new(runnable, file, line_or_range) ⇒ Filter
Instance Method Details
#===(method)
[ GitHub ]# File 'railties/lib/rails/test_unit/runner.rb', line 193
def ===(method) return unless @runnable.method_defined?(method) if @line_range test_file, test_range = definition_for(@runnable.instance_method(method)) test_file == @file && @line_range.overlaps?(test_range) else @runnable.instance_method(method).source_location.first == @file end end
#definition_for(method) (private)
[ GitHub ]# File 'railties/lib/rails/test_unit/runner.rb', line 205
def definition_for(method) TestParser.definition_for(method) end