summaryrefslogtreecommitdiff
path: root/yaksh/test_models.py
diff options
context:
space:
mode:
authorankitjavalkar2018-07-11 17:19:56 +0530
committerankitjavalkar2018-07-13 13:00:36 +0530
commite7c18d17c8b5ed193e4e34bdfe2072951d996530 (patch)
treeabe3e154790aab9213ede12336a06f544ddbc79b /yaksh/test_models.py
parent69a07a92309105b289f4d08957729bda68727bf2 (diff)
downloadonline_test-e7c18d17c8b5ed193e4e34bdfe2072951d996530.tar.gz
online_test-e7c18d17c8b5ed193e4e34bdfe2072951d996530.tar.bz2
online_test-e7c18d17c8b5ed193e4e34bdfe2072951d996530.zip
Fix tests
Diffstat (limited to 'yaksh/test_models.py')
-rw-r--r--yaksh/test_models.py4
1 files changed, 4 insertions, 0 deletions
diff --git a/yaksh/test_models.py b/yaksh/test_models.py
index 403dfb4..deb6654 100644
--- a/yaksh/test_models.py
+++ b/yaksh/test_models.py
@@ -1,4 +1,5 @@
import unittest
+from django.contrib.auth.models import Group
from yaksh.models import User, Profile, Question, Quiz, QuestionPaper,\
QuestionSet, AnswerPaper, Answer, Course, StandardTestCase,\
StdIOBasedTestCase, FileUpload, McqTestCase, AssignmentUpload,\
@@ -24,6 +25,8 @@ from yaksh import settings
def setUpModule():
+ mod_group = Group.objects.create(name='moderator')
+
# create user profile
user = User.objects.create_user(username='creator',
password='demo',
@@ -111,6 +114,7 @@ def tearDownModule():
LearningUnit.objects.all().delete()
LearningModule.objects.all().delete()
AnswerPaper.objects.all().delete()
+ Group.objects.all().delete()
###############################################################################