Index: /main/waeup.kofa/trunk/src/waeup/kofa/mandates/mandate.py
===================================================================
--- /main/waeup.kofa/trunk/src/waeup/kofa/mandates/mandate.py	(revision 8858)
+++ /main/waeup.kofa/trunk/src/waeup/kofa/mandates/mandate.py	(revision 8859)
@@ -57,5 +57,5 @@
         user = self.params.get('user', None)
         pwd = self.params.get('password', None)
-        if user and pwd:
+        if not None in (user, pwd):
             try:
                 IUserAccount(user).setPassword(pwd)
Index: /main/waeup.kofa/trunk/src/waeup/kofa/mandates/tests.py
===================================================================
--- /main/waeup.kofa/trunk/src/waeup/kofa/mandates/tests.py	(revision 8858)
+++ /main/waeup.kofa/trunk/src/waeup/kofa/mandates/tests.py	(revision 8859)
@@ -86,5 +86,4 @@
     def test_set_student_password(self):
         student = createObject('waeup.Student')
-        self.app['students'].addStudent(student)
         # Add and execute a mandate with missing parameters.
         mandate = PasswordMandate()
@@ -123,4 +122,16 @@
         self.assertTrue(IUserAccount(officer).checkPassword('mypwd1'))
 
+    def test_set_applicant_password(self):
+        applicant = createObject('waeup.Applicant')
+        mandate = PasswordMandate()
+        mandate.params['user'] = applicant
+        mandate.params['password'] = 'mypwd1'
+        self.app['mandates'].addMandate(mandate)
+        msg = mandate.execute()
+        # Password has been set.
+        self.assertEqual(msg, 'Password has been successfully set. Proceed to '
+            'the login page and enter your credentials.')
+        self.assertTrue(IUserAccount(applicant).checkPassword('mypwd1'))
+
     def test_remove_expired(self):
         # mandate1 is an old mandate which just expired.
