On Sep 2, 1:49 pm, 7stud -- <li...@ruby-forum.com> wrote: > > User.find(params[:id]) will return user1 > > I really don't care what happens in that case, and I don't understand > why that would cause my tests to fail.
You're missing the point. The point is that in your tests params[:id] isn't a string (because pre rails 3.1 rails didn't force this and would allow you to create params that couldn't exist in the real world) Fred > > With both versions of the code, if the user changes the url from: > > http://localhost:3000/users/1/edit > > to: > > http://localhost:3000/users/4/edit > > then he will be redirected and not allowed to edit user4's info. > > -- > Posted viahttp://www.ruby-forum.com/. -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk@googlegroups.com. To unsubscribe from this group, send email to rubyonrails-talk+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.