On Feb 20, 2008 2:02 AM, Jarkko Laine <[EMAIL PROTECTED]> wrote:
>
> On 19.2.2008, at 20.45, James Deville wrote:
>
> > I set RAILS_ENV in my stories/helper.rb file. That might be a good
> > solution.
> >
> >
> > On Feb 19, 2008, at 10:32 AM, Ed Howland wrote:
> >
> >> Hi,
> >>
> >> I am trying to get Webrat integrated with RSpec. I've followed the
> >> steps in the various blog posts about this, but have one sniggling
> >> little issue. It might be a Webrat issue, but I am hoping the RSpec
> >> folks might have already solved it.
> >>
> >> I have the stories run from a Rake task  (am hoping for one of these
> >> in the main rspec rake task soon,) ut to run webrat stuff in the
> >> steps, you need to:
> >>
> >> rake spec:stories RAILS_ENV=test.
> >>
> >> The reason is due to the boot order of rake and plugins (of which
> >> webrat and rspec are ones), webrat/init.rb doesn't attach itself to
> >> ActionController::Integration::Session unless it is on the test
> >> environment. Only setting the RAILS_ENV ahead of the boot sequence
> >> fixes this. But I am wondering if there is another alternative.
> >>
> >> Also, has anyone gotten it to run with autotest?
>
> Using Webrat for 100% of my stories (and running autotest) and loving
> it. I also have the env set in stories/helper.rb, but I'm not sure
> whether it was there from the beginning (I just copied it from some of
> the early posts about stories).

This is set in the generated stories/helper.rb (when you run
'script/generate rspec').

Cheers,
David

>
> //jarkko
>
> --
> Jarkko Laine
> http://jlaine.net
> http://dotherightthing.com
> http://www.railsecommerce.com
> http://odesign.fi
>
>
>
> _______________________________________________
> rspec-users mailing list
> rspec-users@rubyforge.org
> http://rubyforge.org/mailman/listinfo/rspec-users
>
_______________________________________________
rspec-users mailing list
rspec-users@rubyforge.org
http://rubyforge.org/mailman/listinfo/rspec-users

Reply via email to