Skip to content

Commit 324c681

Browse files
committed
fix: fix test case test_per_course_anonymized_id
1 parent 9c4c049 commit 324c681

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

lms/djangoapps/courseware/tests/test_block_render.py

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1964,7 +1964,10 @@ def test_per_student_anonymized_id(self, block_class):
19641964
self._get_anonymous_id(CourseKey.from_string(course_id), block_class, True)
19651965

19661966
@ddt.data(*PER_COURSE_ANONYMIZED_XBLOCKS)
1967-
def test_per_course_anonymized_id(self, xblock_class):
1967+
@patch('xmodule.x_module.XModuleMixin.bind_for_student')
1968+
def test_per_course_anonymized_id(self, xblock_class, mock_bind_for_student):
1969+
if settings.USE_EXTRACTED_LTI_BLOCK and not hasattr(xblock_class, 'bind_for_student'):
1970+
xblock_class.bind_for_student = mock_bind_for_student
19681971
assert '0c706d119cad686d28067412b9178454' == \
19691972
self._get_anonymous_id(CourseKey.from_string('MITx/6.00x/2012_Fall'), xblock_class, False)
19701973

0 commit comments

Comments
 (0)