# [Rake-devel] Option handling in rake_test_loader.rb

Jim Weirich jim at weirichhouse.org
Fri Aug 19 10:22:19 EDT 2005

Greg Fast said:
> Jim,
>
> Here's a tiny patch to rake_test_loader.rb that makes it ignore command
> line options.  As it is now, you can't do things like `rake test
> TESTOPTS="--runner=fox"`, since it tries to load() "--runner=fox".

Hmmm ... I seem to have no problems with TESTOPTS="--runner=fox".  For
example, given a Rakefile:

puts "Options: [#{ENV['TESTOPTS']}]"
end

The following command seems to work fine:

C:\weirich\pgm\rake>rake TESTOPTS="--runner=fox"
(in C:/weirich/pgm/rake)
Options: [--runner=fox]

This was on a windows XP box.  My linux box behaves in the same way.

What platform were you on where you had trouble.

--
-- Jim Weirich     jim at weirichhouse.org    http://onestepback.org
-----------------------------------------------------------------
"Beware of bugs in the above code; I have only proved it correct,
not tried it." -- Donald Knuth (in a memo to Peter van Emde Boas)