Merged r23343 and r23345 from trunk to 6.0-stable (#41914).

git-svn-id: https://svn.redmine.org/redmine/branches/6.0-stable@23346 e93f8b46-1217-0410-a6f0-8f06a7374b81
This commit is contained in:
Go MAEDA
2024-12-02 01:31:02 +00:00
parent 4d79219d60
commit ecc6f3e438

View File

@@ -564,6 +564,7 @@ class UserTest < ActiveSupport::TestCase
end
def test_validate_password_complexity
set_language_if_valid 'en'
user = users(:users_002)
bad_passwords = [
user.login,
@@ -577,7 +578,7 @@ class UserTest < ActiveSupport::TestCase
user.password = p
user.password_confirmation = p
assert_not user.save
assert user.errors.full_messages.include?('Password is too simple')
assert_includes user.errors.full_messages, 'Password is too simple'
end
end