wrong number of arguments calling `request` (0 for 1) (ArgumentError)

Here is the scenario

Scenario: Successful login

Given an unauthenticated visitor

When visitor goes to /users/login

And fills in Email with: amitpandya

And fills in Password with: amitpandya

And clicks the Login button

Then amitpandya should be logged in

And page should include a notice with text: Welcome amitpandya

And amitpandya should see the home mypage page

now in steps file

When “$person logs in” do |user|

post_via_redirect “/users/login”, {:authenticator => {:username => user, :password => “washington”}},{:https => ‘on’}

request.should_not be_ssl

request.session[:user_id].should == Person.find_by_username(user).id


working fine with cucumber-0.10.0 and cucumber-rails-0.3.2 but if I upgrade with cucumber-rails-1.2.1 or cucumber-rails-1.3.1

I am getting bellow error.

Then amitpandya should be logged in # features/step_definitions/session_steps.rb:11

wrong number of arguments calling request (0 for 1) (ArgumentError)

./features/step_definitions/session_steps.rb:12:in `/^(.*)\ should\ be\ logged\ in$/’

features/login.feature:23:in `Then amitpandya should be logged in’

Any help How can I fix it?

Thank you.

With kind regards,

Amit Pandya

Hi Amit,

I don’t think you’ll get much help from this mailing list. It focuses on Rails Documentation, and doesn’t have much activity.

I think you’ll have better luck asking your question here, https://groups.google.com/forum/#!forum/rubyonrails-talk.

Best of Luck!