Explorar o código

Patch user_password code and tests

Yentl Van Tendeloo %!s(int64=7) %!d(string=hai) anos
pai
achega
0c951f61a0
Modificáronse 2 ficheiros con 3 adicións e 1 borrados
  1. 1 1
      bootstrap/core_algorithm.alc
  2. 2 0
      unit/test_all.py

+ 1 - 1
bootstrap/core_algorithm.alc

@@ -2298,7 +2298,7 @@ String function cmd_user_password(user_name : String, new_password : String):
 		else:
 			return "Unknown user: " + user_name!
 	else:
-		return "User permission denied: " + user_name!
+		return "User permission denied to: " + user_name!
 
 String function cmd_transformation_signature(transformation_name : String):
 	String model_id

+ 2 - 0
unit/test_all.py

@@ -743,6 +743,7 @@ class TestModelverse(unittest.TestCase):
             user_logout()
             login("user2", "user2")
             user_logout()
+            login("user", "user")
 
         # But admin can do that
         self.do_as_user("admin", user_password, ["user2", "user10"])
@@ -760,6 +761,7 @@ class TestModelverse(unittest.TestCase):
             # Check that we can still create the new user with whatever password we want
             login("user10", "user11")
             user_logout()
+            login("user", "user")
 
     def test_op_model_types(self):
         model_add("users/user/test/a", "formalisms/SimpleClassDiagrams")