def has_permission(self, permission):
        """
        Encapsulates lms specific functionality, as `has_permission` is not
        importable outside of lms context, namely in tests.

        :param user:
        :param str permission: Permission
        :rtype: bool
        """
        # normal import causes the xmodule_assets command to fail due to circular import - hence importing locally
        from lms.djangoapps.discussion.django_comment_client.permissions import has_permission

        return has_permission(self.django_user, permission, self.course_key)