Class: Test::Unit::Collector::Dir
- Inherits:
-
Object
- Object
- Test::Unit::Collector::Dir
- Defined in:
- lib/rake/ruby182_test_unit_fix.rb
Overview
Local Rake override to fix bug in Ruby 0.8.2
Instance Method Summary collapse
Instance Method Details
#collect_file(name, suites, already_gathered) ⇒ Object
:nodoc:
10 11 12 13 14 15 16 17 18 19 20 21 |
# File 'lib/rake/ruby182_test_unit_fix.rb', line 10 def collect_file(name, suites, already_gathered) # :nodoc: dir = File.dirname(File.(name)) $:.unshift(dir) unless $:.first == dir if(@req) @req.require(name) else require(name) end find_test_cases(already_gathered).each{|t| add_suite(suites, t.suite)} ensure $:.delete_at $:.rindex(dir) end |