summaryrefslogtreecommitdiff
path: root/yaksh/test_views.py
diff options
context:
space:
mode:
Diffstat (limited to 'yaksh/test_views.py')
-rw-r--r--yaksh/test_views.py10
1 files changed, 8 insertions, 2 deletions
diff --git a/yaksh/test_views.py b/yaksh/test_views.py
index e5308fc..0060ed8 100644
--- a/yaksh/test_views.py
+++ b/yaksh/test_views.py
@@ -3012,12 +3012,18 @@ class TestShowQuestions(TestCase):
data={'file': questions_file,
'upload': 'upload'}
)
+ summaries = ['Roots of quadratic equation', 'Print Output',
+ 'Adding decimals', 'For Loop over String',
+ 'Hello World in File', 'Extract columns from files',
+ 'Check Palindrome', 'Add 3 numbers', 'Reverse a string'
+ ]
+
uploaded_ques = Question.objects.filter(active=True,
- summary="Yaksh Demo Question",
+ summary__in=summaries,
user=self.user).count()
self.assertEqual(response.status_code, 200)
self.assertTemplateUsed(response, 'yaksh/showquestions.html')
- self.assertEqual(uploaded_ques, 3)
+ self.assertEqual(uploaded_ques, 9)
f.close()
dummy_file = SimpleUploadedFile("test.txt", b"test")
response = self.client.post(reverse('yaksh:show_questions'),