Hi, I have problems to implement the tests with RSpec with nested
routes in views, as I implement these tests?
Always gives error that it can not find the routes.

#config/routes.rb

resources :controller1 do
    resources :controller2
end


My test view

#spec/views/controller2/index.html.erb_spec.rb

require 'spec_helper'

describe "controller2/index" do

  it "renders a list of planos" do
    render
  end
end


And return this error

Failure/Error: render
     ActionView::Template::Error:
       No route matches {:controller=>"controller2"}

Can anybody help-me?
Thanks.
_______________________________________________
rspec-users mailing list
rspec-users@rubyforge.org
http://rubyforge.org/mailman/listinfo/rspec-users

Reply via email to