search for: snippetscontrol

Displaying 2 results from an estimated 2 matches for "snippetscontrol".

2007 Nov 07
0
Named routes raising nil.rewrite error
...on => ''version'' map.revert_snippet ''faq/:id/version/:version/revert'', :action => ''revert'' end When trying to write the following spec (a regression), I get the error: ======================================== describe SnippetsController, "routes" do it "should route the snippet_version_url to the version action" do snippet_version_url(:id => "1", :version => "41").should == "/foo" end end ======================================== escher: ./script/spec spec/cont...
2007 Dec 03
4
Resource routing methods -- what am I missing?
...for a while now, so whatever I''m missing must be something stupid and obvious... Anyone care to help me out? -- routes.rb: # ... map.resources :algorithms, :collection => { :search => :post } do |algorithm| algorithm.resources :snippets end # ... -- snippets_controller.rb class SnippetsController < ApplicationController def show # ... end end -- algorithms_controller.rb class AlgorithmsController < ApplicationController # ... redirect_to algorithm_snippet_url(@algorithm, @snippet) # <- no such method redirect_to snippet_url(@algorithm, @snippet) # <- no suc...