slow rails environment load for unit tests, etc on windows


I'm using windoze 7 and rails 3.0.
Running my unit tests takes a very long time for the rails environment
to load... somewhere around 20 seconds, maybe more.

I have seen references to using faster_require... i have done the gem
install for that, but have no clue what to do with it. Am I missing
something as far as setting that up?

what db are you using?

On thing I ran into is at work my "home path" was pointing to a
network drive and my gems were being saved there. My test took 10
minutes to run. I had the network admin change my "home path" to my C
drive and I reinstalled my gems and my tests ran much faster. Like
less than one minute. My test always run slower on windows than my

John Ivanoff

I am using sqlite.
re: faster_require, I am able to do a requires 'faster_require' from a
ruby console, but cannot do so in rails console without an error.
I have tried placing an entry in the gemfile and gemfile.lock files.

Here's the behavior I am getting now....
So, I add entries in gemfile and gemfile.lock
I place a require 'faster_require' in the boot.rb file.

run gem install
then I can run rake test:units. The strange thing is that I can only
do a rake test:units one time... or instead do a rails console one
the second time I try running a rails console (without any changes)
the console or tests fail to load, barfing out a rather long error
I do another gem install faster_require.... and can run console or
test again... just one time.


are you sending mail in your app??

Windows will always be slow with the stock rails app. Windows will
load the rails environment every time which takes about 20 secs on my
vista box.

I've recently looked into this after taking several minutes to debug
some tests. One of the possible solutions is to use to RSpec. I'm no
expert on it as I couldn't install it on ruby 1.8.7 (window - got to
love it). But supposedly RSpec has a server that loads the environment
only once.