Hello. I have a problem trying to use cucumber with webrat. I thought I could use the gems versions of rspec, rspec-rails, cucumber and webrat, in fact I think that I could manage to do it two weeks ago, but now that I updated the versions of the rspec, rspec-rails and cucumber, I am getting a errors like this undefined method `visits'' for #<ActionController::Integration::Session:0xb702e6a0> (NoMethodError) for all the webrat methods. Am I right.? Can I use webrat via the gem.? Or do I have to install webrat in vendor/plugins directory.? Thanks -- Posted via http://www.ruby-forum.com/.
The webrat gem works for me. Do you have "require ''webrat''" in your features/steps/env.rb file? Mark. Juanma Cervera wrote:> Hello. > > I have a problem trying to use cucumber with webrat. > I thought I could use the gems versions of rspec, rspec-rails, cucumber > and webrat, in fact I think that I could manage to do it two weeks ago, > but now that I updated the versions of the rspec, rspec-rails and > cucumber, I am getting a errors like this > > undefined method `visits'' for > #<ActionController::Integration::Session:0xb702e6a0> (NoMethodError) > > for all the webrat methods. > > Am I right.? Can I use webrat via the gem.? Or do I have to install > webrat in vendor/plugins directory.? > > Thanks >-------------- next part -------------- An HTML attachment was scrubbed... URL: <http://rubyforge.org/pipermail/rspec-users/attachments/20081027/6ca83048/attachment.html>
On Mon, Oct 27, 2008 at 3:54 PM, Juanma Cervera <lists at ruby-forum.com> wrote:> Hello. > > I have a problem trying to use cucumber with webrat. > I thought I could use the gems versions of rspec, rspec-rails, cucumber > and webrat, in fact I think that I could manage to do it two weeks ago, > but now that I updated the versions of the rspec, rspec-rails and > cucumber, I am getting a errors like this > > undefined method `visits'' for > #<ActionController::Integration::Session:0xb702e6a0> (NoMethodError) > > for all the webrat methods. > > Am I right.? Can I use webrat via the gem.? Or do I have to install > webrat in vendor/plugins directory.? >Do you require ''webrat'' anywhere?> Thanks > -- > Posted via http://www.ruby-forum.com/. > _______________________________________________ > rspec-users mailing list > rspec-users at rubyforge.org > http://rubyforge.org/mailman/listinfo/rspec-users >
On Mon, 2008-10-27 at 15:54 +0100, Juanma Cervera wrote:> I have a problem trying to use cucumber with webrat. > I thought I could use the gems versions of rspec, rspec-rails, cucumber > and webrat, in fact I think that I could manage to do it two weeks ago, > but now that I updated the versions of the rspec, rspec-rails and > cucumber, I am getting a errors like this > > undefined method `visits'' for > #<ActionController::Integration::Session:0xb702e6a0> (NoMethodError)I just ran into this myself. I added a "require ''webrat''" to env.rb to fix it. Kind regards, Hans -------------- next part -------------- A non-text attachment was scrubbed... Name: not available Type: application/pgp-signature Size: 197 bytes Desc: This is a digitally signed message part URL: <http://rubyforge.org/pipermail/rspec-users/attachments/20081027/c7fcf322/attachment.bin>
Thanks Mark That was the problem Mark Thomson wrote:> The webrat gem works for me. Do you have "require ''webrat''" in your > features/steps/env.rb file? > > Mark.-- Posted via http://www.ruby-forum.com/.
Last time I looked, webrat is only patched in when you''re running with RAILS_ENV == "test". Are you definitely doing that? On 27 Oct 2008, at 15:28, Mark Thomson wrote:> The webrat gem works for me. Do you have "require ''webrat''" in your > features/steps/env.rb file? > > Mark. > > > > Juanma Cervera wrote: >> >> Hello. >> >> I have a problem trying to use cucumber with webrat. >> I thought I could use the gems versions of rspec, rspec-rails, >> cucumber >> and webrat, in fact I think that I could manage to do it two weeks >> ago, >> but now that I updated the versions of the rspec, rspec-rails and >> cucumber, I am getting a errors like this >> >> undefined method `visits'' for >> #<ActionController::Integration::Session:0xb702e6a0> (NoMethodError) >> >> for all the webrat methods. >> >> Am I right.? Can I use webrat via the gem.? Or do I have to install >> webrat in vendor/plugins directory.? >> >> Thanks >> > _______________________________________________ > rspec-users mailing list > rspec-users at rubyforge.org > http://rubyforge.org/mailman/listinfo/rspec-users