Created
April 23, 2009 00:17
-
-
Save ohammersmith/100184 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| describe "#route_for" do | |
| it "should be nested shallowly under forums as topics" do | |
| params_from(:get, '/forums/123/topics').should == {:controller => "forum_posts", :action => "index", :forum_id => "123" } | |
| end | |
| it "should be nested shallowly under topics as posts" do | |
| params_from(:get, '/topics/123/posts').should == {:controller => "forum_posts", :action => "index", :topic_id => "123" } | |
| params_from(:get, '/posts/321').should == {:controller => "forum_posts", :action => "show", :id => "321" } | |
| end | |
| end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment