Ejemplo n.º 1
0
 def post(self):
     user = self.get_argument("username", None)
     email = self.get_argument("email" , None)
     password = self.get_argument("password", None)
     password2 = self.get_argument("password2", None)
     if all([user, email, password, password2]):
         user = create_new_user(user, email, password, password2)
         if user:
             self.redirect(user.link)
Ejemplo n.º 2
0
 def setup_user(self):
     user_name = 'test%s'%random.randint(0, 100)
     user = create_new_user(user_name, '*****@*****.**'%user_name, 'test1', 'test1')
     return user