method

collect_file

ruby latest stable - Class: Test::Unit::Collector::Dir

Method deprecated or moved

This method is deprecated or moved on the latest stable version. The last existing version (v2_2_9) is shown here.

collect_file(name, suites, already_gathered)
public

No documentation available.

# File lib/rake/ruby182_test_unit_fix.rb, line 12
        def collect_file(name, suites, already_gathered) # :nodoc:
          dir = File.dirname(File.expand_path(name))
          $:.unshift(dir) unless $:.first == dir
          if @req
            @req.require(name)
          else
            require(name)
          end
          find_test_cases(already_gathered).each do |t|
            add_suite(suites, t.suite)
          end
        ensure
          $:.delete_at $:.rindex(dir)
        end