'Create staff user and course blocks accessible by that user'

def create_staff_context(self):

    staff_user = UserFactory.create()
    CourseStaffRole(self.course.location.course_key).add_users(staff_user)
    block_structure = get_course_blocks(staff_user, self.course.location, self.transformers)
    return {'request': MagicMock(), 'block_structure': block_structure, 'requested_fields': ['type']}
