[Rake-devel] Re: rake unittests fails

Jim Weirich jim at weirichhouse.org
Tue Apr 12 23:21:46 EDT 2005


On Tuesday 12 April 2005 09:06 pm, Lionel Thiry wrote:
> Lionel Thiry a écrit :
> > On win2k, when running rake tests, it seems to loop at some point (and
> > there are errors). I've done it with rake-0.5.3.
[...]
> > C:\usr\ruby\lib\ruby\gems\1.8\gems\rake-0.5.3>rake
> > (in C:/usr/ruby/lib/ruby/gems/1.8/gems/rake-0.5.3)
> > ruby -Ilib -w
[...]
> > UNABLE TO RUN FUNCTIONAL TESTS
> > No Session Found
> > Started
> > EEEEEEEEEEEE.............................................

I've not seen the looping test problem before.  I am using a new test loader 
(after testrb caused its own problems).  Try the following.

The Session class is needed for the functional tests, unfortunately it doesn't 
work properly under Windows ... so the functional tests are disabled.  So try 
running just the unittests.  Like this ...

  rake unittests

If that doesn't help, try switching to an alternative test loader.  Edit the 
rakefile to say ...

  Rake::TestTask.new(:unittests) do |t|
    t.test_files = FileList['test/test*.rb']
    t.warning = true
    t.verbose = false
    t.loader = :testrb                    # add this line
  end

> There is another problem when testing an older rake version with a newer 
> version installed: tests are runned with the latest version.

Hmmm ... I test cross versions all the time, but usually it is an older 
version testing a newer version.  The unit tests are run as a separate 
process and the load paths are setup to pick up the version under test.

Try this command (from the top directory of the Rake source tree):

  ruby -Ilib bin/rake --version

It should report the version of the rake software being tested (rather than 
the version of rake installed).  

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