Instead of using "user.valid?", how can I make it more specific so I'm just testing the password attribute?
On Sep 2, 1:30 am, Philip Hallstrom <[email protected]> wrote: > This test is meant to test one thing -- that a password must be at least 8 > characters. Testing "user.valid?" tests much more than that. That could be > false for any number of reasons -- perhaps you have a validation that rejects > "example.com" as a valid email address. > > I would test that at least one error exists on the :password attribute for > the user -- 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 [email protected]. To unsubscribe from this group, send email to [email protected]. For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.

