增加用户密码修改成功的API测试,以及增加用户邮箱字段并做了相应的API测试,目前的account/view.py测试覆盖率为100%

This commit is contained in:
hohoTT
2015-08-05 20:11:25 +08:00
parent 17b44800ca
commit 117a6d3525
6 changed files with 99 additions and 8 deletions

View File

@@ -19,6 +19,8 @@ class User(AbstractBaseUser):
username = models.CharField(max_length=30, unique=True)
# 真实姓名
real_name = models.CharField(max_length=30, blank=True, null=True)
# 用户邮箱
email = models.EmailField(max_length=254, blank=True, null=True)
admin_group = models.ForeignKey(AdminGroup, null=True, on_delete=models.SET_NULL)
USERNAME_FIELD = 'username'