]> source.dussan.org Git - redmine.git/commitdiff
Fix passing a wrong parameter to `with_settings` in UserTest::test_random_password_in...
authorGo MAEDA <maeda@farend.jp>
Sat, 16 Jul 2022 05:31:41 +0000 (05:31 +0000)
committerGo MAEDA <maeda@farend.jp>
Sat, 16 Jul 2022 05:31:41 +0000 (05:31 +0000)
Patch by Go MAEDA.

git-svn-id: https://svn.redmine.org/redmine/trunk@21705 e93f8b46-1217-0410-a6f0-8f06a7374b81

test/unit/user_test.rb

index dde1cdd6226cb89f4d8e2d7ff735c62c5bbff9b4..53e7693ff24a714b589b1d7ca7af4f300c287aa5 100644 (file)
@@ -1099,7 +1099,7 @@ class UserTest < ActiveSupport::TestCase
   end
 
   def test_random_password_include_required_characters
-    with_settings :password_required_char_classes => Setting::PASSWORD_CHAR_CLASSES do
+    with_settings :password_required_char_classes => Setting::PASSWORD_CHAR_CLASSES.keys do
       u = User.new(:firstname => "new", :lastname => "user", :login => "random", :mail => "random@somnet.foo")
       u.random_password
       assert u.valid?