I have disabled user registration (Gem Devise) and I want to do a test to make sure that the route /users/sign_up does not exist.
To do this, I created a test in spec/features/user_spec.rb
require 'spec_helper' require 'capybara/rspec' feature "Users" do scenario "could not register " do expect(:get => "/users/sign_up").not_to be_routable end end
When I run this test, I have this error:
1) Users could not register Failure/Error: expect(:get => "/users/sign_up").not_to be_routable NoMethodError: undefined method `routable?' for {:get=>"/users/sign_up"}:Hash # ./spec/features/user_spec.rb:8:in `block (2 levels) in <top (required)>'
source share