aboutsummaryrefslogtreecommitdiffstats
path: root/activemodel/test/cases/secure_password_test.rb
diff options
context:
space:
mode:
Diffstat (limited to 'activemodel/test/cases/secure_password_test.rb')
-rw-r--r--activemodel/test/cases/secure_password_test.rb13
1 files changed, 2 insertions, 11 deletions
diff --git a/activemodel/test/cases/secure_password_test.rb b/activemodel/test/cases/secure_password_test.rb
index abbd182f66..279a908aeb 100644
--- a/activemodel/test/cases/secure_password_test.rb
+++ b/activemodel/test/cases/secure_password_test.rb
@@ -189,8 +189,8 @@ class SecurePasswordTest < ActiveModel::TestCase
assert !@user.authenticate("wrong")
assert @user.authenticate("secret")
- assert !@user.authenticate("wrong", :activation_token)
- assert @user.authenticate("new_token", :activation_token)
+ assert !@user.authenticate_activation_token("wrong")
+ assert @user.authenticate_activation_token("new_token")
end
test "Password digest cost defaults to bcrypt default cost when min_cost is false" do
@@ -219,13 +219,4 @@ class SecurePasswordTest < ActiveModel::TestCase
@user.password = "secret"
assert_equal BCrypt::Engine::MIN_COST, @user.password_digest.cost
end
-
- test "regenerate attribute method" do
- old_digest = @user.activation_token_digest
- @user.regenerate_activation_token
-
- assert_not_nil @user.activation_token
- assert_not_nil @user.activation_token_digest
- assert_not_equal old_digest, @user.activation_token_digest
- end
end