Hello,
I am trying to spec an action in a controller, and rspec doesn't find
a route.
It seems that problem is in ":viewtype". If I change a line
"/:viewtype/asset/add"
into "/context/asset/add" in routes it works.
I tried also
post "/context/asset/add", no luck.
Could you please let me know how I can call the action through
that route with post method?
Thank you in advance,
Evgeny
=====================
map.with_options(:controller => "assets", :conditions =>{:method
=> :post}) do |m|
m.create_asset '/:viewtype/asset/
add', :action => 'create'
end
describe AssetsController, "when working with formats" do
it "should call a find_asset_format for some actions" do
post :create
end
end
_______________________________________________
rspec-users mailing list
[email protected]
http://rubyforge.org/mailman/listinfo/rspec-users