Closed foxnewsnetwork closed 12 years ago
The workaround is now to just write all the routes myself.
I just tried doing resources :cats and it appears in the routes.
Not sure why it's not working for you but did you put resources :cats rather than resource :cats.
I'll look at the user#index to see whats wrong.
My previous comment made me realize that something was wrong with our routes
Everything follows resources :cats, but it was resource :index, so for some reason resource was not plural. Not sure why this didn't throw an error but it worked for some reason. Changing it to be the proper resources :index fixes it however and all the tests pass as they should.
Close this error when you've confirmed everything.
well, it looks like all the junk is working now. If I ever become an elementary school teacher who teaches grammar, I will use this particular story to illustrate to the children the importance of differentiating between singular and plural nouns.
We initially didn't think much of it when one of the specs didn't pass. So what if it can't render users#index correctly? We thought, we'll just put in a work-around! But we were wrong
This is apparently a major problem as now, for some strange reason, the resource macro in routes.rb is broken. For example inputting:
resource :cats
into config/routes.rb
then running rake routes no longer returns any show path or anything that has /cats/:id in it.