restful_authentication - some default tests failing

Hey all

I just installed restful_authentication in a new project and have run it's specs. I'm getting a few failures. Just looking at the first, i can't understand why it's failing - can anyone see?

#failing line from test route_for(:controller => 'users', :action => 'update', :id => '1').should == "/users/1"

#reported reason for failure The recognized options <{"action"=>"show", "id"=>"1", "controller"=>"users"}> did not match <{"action"=>"update", "id"=>"1", "controller"=>"users"}>, difference: <{"action"=>"update"}> If you're expecting this failure, we suggest {:get=>"/users/1"}.should_not be_routable

So, it looks like "/users/1" with a put isn't pointing to update. But, when i do rake routes i see

  user GET /users/:id(.:format) {:controller=>"users", :action=>"show"}        PUT /users/:id(.:format) {:controller=>"users", :action=>"update"}        DELETE /users/:id(.:format) {:controller=>"users", :action=>"destroy"}

It looks like the route should work. And, in the console i can do this:

include Spec::Rails::Example::RoutingHelpers

=> Object

params_from(:put, '/users/1')

=> {:action=>"update", :controller=>"users", :id=>"1"}

So, i don;t understand why the test is failing. Any ideas?

thanks - max

Max Williams wrote:

Hey all

I just installed restful_authentication in a new project

Do yourself a favor and take it right back out again. Restful_auth is based on unmaintainable, untestable generated crap code; it has no place in today's Rails ecosystem. Use Authlogic instead, which is actually designed properly.

Best,

Thanks Marnen, AuthLogic does look good actually.