def test_passwort_gen(self):
     p = Password_Generator(oldstyle=True)
     pw = p.gen()
     print pw
     assert(len(pw) == 10)
     p = Password_Generator()
     pw = p.gen()
     #re.compile(r'[a-z]')
     print pw
     assert(pw)
 def test_passwort_gen(self):
     p = Password_Generator(oldstyle=True)
     pw = p.gen()
     print pw
     assert (len(pw) == 10)
     p = Password_Generator()
     pw = p.gen()
     #re.compile(r'[a-z]')
     print pw
     assert (pw)
Beispiel #3
0
 def reset_password(self):
     p = Password_Generator()
     passwd = p.gen()
     # check email
     email = self.signup_email
     if self.profile.email in ['', None]:
         email = self.profile.email
     # mailout passwort
     reset_msg = Message("Hello",
                         sender="*****@*****.**",
                         recipients=[email])
     reset_msg.body = """Your new Passwort is: %s""" % (passwd)
     mail.send(reset_msg)
     self.password = passwd
     return passwd
Beispiel #4
0
 def reset_password(self):
     p = Password_Generator()
     passwd = p.gen()
     # check email
     email = self.signup_email
     if self.profile.email in ['', None]:
         email = self.profile.email
     # mailout passwort
     reset_msg = Message("Hello",
                         sender="*****@*****.**",
                         recipients=[email])
     reset_msg.body = """Your new Passwort is: %s""" % (passwd)
     mail.send(reset_msg)
     self.password = passwd
     return passwd