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 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
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)