Sal-laS
Sal-laS

Reputation: 11639

No route matches [GET] "/" (ActionController::RoutingError)

I have an application running on this url correctly

http://workspace-username.c9users.io/?#/bookings

and i have my server running on port 8081.

When i run my cucumber in line

visit  http://workspace-username.c9users.io/?#/bookings 

it gives me the erorr:

   No route matches [GET] "/" (ActionController::RoutingError)

I just got suprised because, the application is running as well, but capybara can not get it. I have also tried

visit  http://workspace-username.c9users.io:8081/?#/bookings 

but still got the same erorr

Upvotes: 0

Views: 983

Answers (1)

AdamCooper86
AdamCooper86

Reputation: 4227

When accessing external pages capybara needs to use a web driver other than racktest because racktest only talks to rack applications. To test the website you will want to use another driver like selenium.

You could set the driver to selenium if you only need it for that test.

Capybara.current_driver = :selenium

Or change the default driver when you configure rspec

Capybara.default_driver = :selenium

Upvotes: 1

Related Questions