Allow Studio override of Feature Based Enrollment status for individual xblocks
This commit is contained in:
@@ -4,7 +4,7 @@ Test the partitions and partitions service
|
||||
"""
|
||||
|
||||
from unittest import TestCase
|
||||
from mock import Mock
|
||||
from mock import Mock, patch
|
||||
|
||||
from opaque_keys.edx.locator import CourseLocator
|
||||
from stevedore.extension import Extension, ExtensionManager
|
||||
@@ -434,6 +434,18 @@ class PartitionServiceBaseClass(PartitionTestCase):
|
||||
|
||||
def setUp(self):
|
||||
super(PartitionServiceBaseClass, self).setUp()
|
||||
|
||||
content_gating_flag_patcher = patch(
|
||||
'openedx.features.content_type_gating.partitions.CONTENT_TYPE_GATING_FLAG.is_enabled',
|
||||
return_value=True,
|
||||
).start()
|
||||
self.addCleanup(content_gating_flag_patcher.stop)
|
||||
content_gating_ui_flag_patcher = patch(
|
||||
'openedx.features.content_type_gating.partitions.CONTENT_TYPE_GATING_STUDIO_UI_FLAG.is_enabled',
|
||||
return_value=True,
|
||||
).start()
|
||||
self.addCleanup(content_gating_ui_flag_patcher.stop)
|
||||
|
||||
self.course = Mock(id=CourseLocator('org_0', 'course_0', 'run_0'))
|
||||
self.partition_service = self._create_service("ma")
|
||||
|
||||
|
||||
Reference in New Issue
Block a user