def test_role_model(self):
"""
Test number of records in Role table
"""
# create test role
role = Role(name="CEO", description="Run the whole company")
# save role to database
db.session.add(role)
db.session.commit()
self.assertEqual(Role.query.count(), 1)
test_back_end.py 文件源码
python
阅读 20
收藏 0
点赞 0
评论 0
评论列表
文章目录