Commit 84c4b7f1 by Vik Paruchuri

Test fixes

parent 480e97a3
...@@ -134,7 +134,7 @@ class ContentStoreToyCourseTest(ModuleStoreTestCase): ...@@ -134,7 +134,7 @@ class ContentStoreToyCourseTest(ModuleStoreTestCase):
self.check_components_on_page(ADVANCED_COMPONENT_TYPES, ['Video Alpha', self.check_components_on_page(ADVANCED_COMPONENT_TYPES, ['Video Alpha',
'Word cloud', 'Word cloud',
'Annotation', 'Annotation',
'Open Ended Grading', 'Open Response Assessment',
'Peer Grading Interface']) 'Peer Grading Interface'])
def test_advanced_components_require_two_clicks(self): def test_advanced_components_require_two_clicks(self):
......
...@@ -614,14 +614,14 @@ class CombinedOpenEndedV1Module(): ...@@ -614,14 +614,14 @@ class CombinedOpenEndedV1Module():
return self.out_of_sync_error(data) return self.out_of_sync_error(data)
self.student_attempts +=1 self.student_attempts +=1
if self.student_attempts >= self.attempts: if self.student_attempts >= self.max_attempts:
return { return {
'success': False, 'success': False,
# This is a student_facing_error # This is a student_facing_error
'error': ( 'error': (
'You have attempted this question {0} times. ' 'You have attempted this question {0} times. '
'You are only allowed to attempt it {1} times.' 'You are only allowed to attempt it {1} times.'
).format(self.student_attempts, self.attempts) ).format(self.student_attempts, self.max_attempts)
} }
self.state = self.INITIAL self.state = self.INITIAL
self.ready_to_reset = False self.ready_to_reset = False
......
...@@ -335,7 +335,7 @@ class CombinedOpenEndedModuleTest(unittest.TestCase): ...@@ -335,7 +335,7 @@ class CombinedOpenEndedModuleTest(unittest.TestCase):
's3_interface': test_util_open_ended.S3_INTERFACE, 's3_interface': test_util_open_ended.S3_INTERFACE,
'open_ended_grading_interface': test_util_open_ended.OPEN_ENDED_GRADING_INTERFACE, 'open_ended_grading_interface': test_util_open_ended.OPEN_ENDED_GRADING_INTERFACE,
'skip_basic_checks': False, 'skip_basic_checks': False,
'is_graded': True, 'graded': True,
} }
oeparam = etree.XML(''' oeparam = etree.XML('''
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment