예제 #1
0
 def test_user_administrator(self):
     """
     is_administrator should always be is_moderator
     """
     user = UserModel(is_administrator=True)
     user.save()
     self.assertTrue(user.is_moderator)
예제 #2
0
 def test_user_superuser(self):
     """
     is_superuser should always be is_administrator and is_moderator
     test model
     """
     user = UserModel(is_superuser=True)
     user.save()
     self.assertTrue(user.is_administrator)
     self.assertTrue(user.is_moderator)