'Tests that an explicitly staff-locked section and all of its children are visible to staff only.'

def test_staff_only_section(self):

    chapter = self._create_child(self.course, 'chapter', 'Test    Chapter', staff_only=True)
    sequential = self._create_child(chapter, 'sequential', 'Test    Sequential')
    vertical = self._create_child(sequential, 'vertical', 'Unit')
    xblock_info = self._get_xblock_info(chapter.location)
    self._verify_visibility_state(xblock_info, VisibilityState.staff_only)
    self._verify_visibility_state(xblock_info, VisibilityState.staff_only, path=self.FIRST_SUBSECTION_PATH)
    self._verify_visibility_state(xblock_info, VisibilityState.staff_only, path=self.FIRST_UNIT_PATH)
    self._verify_explicit_staff_lock_state(xblock_info, True)
    self._verify_explicit_staff_lock_state(xblock_info, False, path=self.FIRST_SUBSECTION_PATH)
    self._verify_explicit_staff_lock_state(xblock_info, False, path=self.FIRST_UNIT_PATH)
    vertical_info = self._get_xblock_info(vertical.location)
    add_container_page_publishing_info(vertical, vertical_info)
    self.assertEqual(_xblock_type_and_display_name(chapter), vertical_info['staff_lock_from'])
