> On Oct 14, 7:49 pm, Nick <[EMAIL PROTECTED]> wrote:
> > With that in mind, how would you configure a plugin to be loaded only
> > in the development environment, and not in the test environment? Since
> > running a suite of tests first jumps into the development environment,
> > I'm not sure how to go about this.

On Oct 14, 3:32 pm, Frederick Cheung <[EMAIL PROTECTED]>
wrote:
> you could certainly bracket the body of your init.rb with "if
> RAILS_ENV ==" and do nothing if not (except perhaps remove your
> plugin's lib directory from the load path)
>
> Fred

Hi Fred. I'm afraid I don't follow. If I put this in a plugin's
init.rb :
    require 'foobar' if RAILS_ENV == 'development'
Then 'foobar' will be loaded whenever any test suite, such as ``rake
test'' or ``rake spec'', is run, because rake initially loads the
development environment.
-Nick
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Ruby 
on Rails: Talk" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/rubyonrails-talk?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to