madeindjs/api_on_rails

Failure during a rake test because of wrong password attribute in test/models/user_test.rb

avalou opened this issue · 2 comments

In the test/models/user_test.rb file, I think
test 'user with a valid email should be valid' do user = User.new(email: 'test@test.org', **password_digest**: 'test') assert user.valid? end

should rather be :

test 'user with a valid email should be valid' do user = User.new(email: 'test@test.org', **password**: 'test') assert user.valid? end

In my case it caused a failure during a rake test.

Thanks for reporting this. I will correct it soon!

Corrected by #66 . But for me tests passed with both:

  • User.new(email: 'test@test.org', password: 'test')
  • User.new(email: 'test@test.org', password_digest: 'test')