[Rake-devel] testtasks.rb failure

Jim Weirich jim at weirichhouse.org
Tue May 3 00:19:07 EDT 2005

On Monday 02 May 2005 06:07 pm, Lionel Thiry wrote:
> Perfectly? With no output?
> testtasks.rb works, I'm sure of it, as my recent tests show it.
> But is it normal that "rake test TEST=test/testtasks.rb" gives no output?

No, but the problem was mine.  I used to have a target named 'test' that ran 
the unit tests.  In a recent fit of organization, I renamed all the test taks 
to be more descriptive (e.g. alltests, functionaltests) and had a set of 
short aliases to run them.

So task :test no longer exists.  When you run it, Rake finds the "test" 
directory and thinks that task "test" is complete (i.e. the file is built), 
so it doesn't produce output.

I've incorporated the patches on this list and committed them to the Rake CVS.  
I also made a beta version available at 
http://onestepback.org/betagems if you want to try it out.  Let me know if I 
missed anything (there was a lot of traffic today).

Some random notes:

* I included the C: tests for win32.  They actually run under unix if forward 
slashes are used (c: is just treated as a file name, not a device).  Coding 
it with backslashes will fail under unix.  I could use a conditional around 
the test and only run it under windows, but I question the value of having 
unit tests that are not run on the primary development platform, nor 
available in any accessible remote testing platform.

* I implemented the new directory path algorithm in a separate function that 
yields partial pathnames.  This allowed me to test the algorithm more 

* I didn't rearrange the test files as was suggested.  Its late already, but I 
hope to get to it soon.

Thanks to everyone for their suggestions.

-- 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)

More information about the Rake-devel mailing list