On Apr 8, 9:36 am, Jonathan Rochkind <[email protected]> wrote:
> Is there a trick for setting this up fairly simply so rspec will work?
> All I've been able to find googling is pretty old instructions/advice
> that doesn't seem to work quite right on contemporary Rails 2.x systems.

I have this exact problem. I'm refactoring the Foreigner gem and it
has some dependencies against Rails. I originally took
plugin_test_helper and attempted to make it more rspec compatible
before I realized that I did not need to load the full Rails stack. I
only needed ActiveSupport, ActiveRecord, and ActiveRecord::Migration
to run my tests. I have those things loaded in the environment.

You might want to check out plugin_test_helper to see how it gives you
callbacks to patch into the environment and initialization process,
and setting up different kinds of fake rails root.

Ho-Sheng Hsiao

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