Merge pull request #21797 from edx/feanil/fix_xmodule_format_failure

Division changed in python3 to produce floats even when you divide tw…
This commit is contained in:
Feanil Patel
2019-09-26 15:49:25 -04:00
committed by GitHub

View File

@@ -218,7 +218,7 @@ class DraftPublishedOpTestCourseSetup(unittest.TestCase):
parent_id = 'course'
for idx in range(num_items):
if parent_type != 'course':
parent_id = _make_block_id(parent_type, idx / 2)
parent_id = _make_block_id(parent_type, idx // 2)
parent_item = getattr(self, parent_id)
block_id = _make_block_id(block_type, idx)
setattr(self, block_id, ItemFactory.create(