diff options
author | ankitjavalkar | 2017-03-03 16:35:18 +0530 |
---|---|---|
committer | ankitjavalkar | 2017-03-06 17:35:17 +0530 |
commit | d0d4c9ab3a409c68766bc044825bf22b0519f6a3 (patch) | |
tree | 2204a5b84caa3db7595c9ad6341964166b146190 /yaksh/test_models.py | |
parent | 0f2a42799d3140de132c203cc255516caa69d617 (diff) | |
download | online_test-d0d4c9ab3a409c68766bc044825bf22b0519f6a3.tar.gz online_test-d0d4c9ab3a409c68766bc044825bf22b0519f6a3.tar.bz2 online_test-d0d4c9ab3a409c68766bc044825bf22b0519f6a3.zip |
Multiple changes:
- Fix movement from one question to another in next_question
- Fix random display of errors from MCQs
- Add Notification display if question has been attempted
- Fix test cases for changes made
Diffstat (limited to 'yaksh/test_models.py')
-rw-r--r-- | yaksh/test_models.py | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/yaksh/test_models.py b/yaksh/test_models.py index a8d48e2..b6934e3 100644 --- a/yaksh/test_models.py +++ b/yaksh/test_models.py @@ -694,7 +694,7 @@ class AnswerPaperTestCases(unittest.TestCase): # Then self.assertTrue(next_question_id is not None) - self.assertEqual(next_question_id.id, 2) + self.assertEqual(next_question_id.id, 1) # Given, last question in the list current_question_id = 3 @@ -704,7 +704,7 @@ class AnswerPaperTestCases(unittest.TestCase): # Then self.assertTrue(next_question_id is not None) - self.assertEqual(next_question_id.id, 2) + self.assertEqual(next_question_id.id, 1) # Test get_questions_answered() method # When @@ -735,13 +735,13 @@ class AnswerPaperTestCases(unittest.TestCase): # Then self.assertEqual(self.answerpaper.questions_left(), 0) - self.assertTrue(current_question is None) + self.assertTrue(current_question is not None) # When next_question_id = self.answerpaper.next_question(current_question_id) # Then - self.assertTrue(next_question_id is None) + self.assertTrue(next_question_id is not None) def test_update_marks(self): """ Test update_marks method of AnswerPaper""" |