I have defined a custom route in routes.rb
get "packages/city/:location_id", to: "packages#index"
In controller_spec.rb,
get :index
gives this error, ActionController::UrlGenerationError: No route matches {:action=>"index", :controller=>"packages"}
How to explicitly specify the custom routes in controller specs?
Aucun commentaire:
Enregistrer un commentaire