chore: Applied lint-amnesty on openedx/core/djangoapps
This commit is contained in:
@@ -12,8 +12,8 @@ from openedx.core.djangoapps.agreements.api import (
|
||||
get_integrity_signatures_for_course,
|
||||
)
|
||||
from openedx.core.djangolib.testing.utils import skip_unless_lms
|
||||
from xmodule.modulestore.tests.django_utils import SharedModuleStoreTestCase
|
||||
from xmodule.modulestore.tests.factories import CourseFactory
|
||||
from xmodule.modulestore.tests.django_utils import SharedModuleStoreTestCase # lint-amnesty, pylint: disable=wrong-import-order
|
||||
from xmodule.modulestore.tests.factories import CourseFactory # lint-amnesty, pylint: disable=wrong-import-order
|
||||
|
||||
LOGGER_NAME = "openedx.core.djangoapps.agreements.api"
|
||||
|
||||
|
||||
@@ -18,8 +18,8 @@ from openedx.core.djangoapps.agreements.api import (
|
||||
)
|
||||
from openedx.core.djangoapps.agreements.toggles import ENABLE_INTEGRITY_SIGNATURE
|
||||
from openedx.core.djangolib.testing.utils import skip_unless_lms
|
||||
from xmodule.modulestore.tests.django_utils import ModuleStoreTestCase
|
||||
from xmodule.modulestore.tests.factories import CourseFactory
|
||||
from xmodule.modulestore.tests.django_utils import ModuleStoreTestCase # lint-amnesty, pylint: disable=wrong-import-order
|
||||
from xmodule.modulestore.tests.factories import CourseFactory # lint-amnesty, pylint: disable=wrong-import-order
|
||||
|
||||
|
||||
@skip_unless_lms
|
||||
|
||||
@@ -11,7 +11,7 @@ from opaque_keys.edx.keys import UsageKey
|
||||
|
||||
from openedx.core.djangoapps.bookmarks.api import BookmarksLimitReachedError
|
||||
from openedx.core.djangolib.testing.utils import skip_unless_lms
|
||||
from xmodule.modulestore.exceptions import ItemNotFoundError
|
||||
from xmodule.modulestore.exceptions import ItemNotFoundError # lint-amnesty, pylint: disable=wrong-import-order
|
||||
|
||||
from .. import api
|
||||
from ..models import Bookmark
|
||||
|
||||
@@ -15,10 +15,10 @@ from opaque_keys.edx.locator import BlockUsageLocator, CourseLocator
|
||||
|
||||
from openedx.core.djangolib.testing.utils import skip_unless_lms
|
||||
from common.djangoapps.student.tests.factories import AdminFactory, UserFactory
|
||||
from xmodule.modulestore import ModuleStoreEnum
|
||||
from xmodule.modulestore.django import modulestore
|
||||
from xmodule.modulestore.tests.django_utils import ModuleStoreTestCase
|
||||
from xmodule.modulestore.tests.factories import CourseFactory, ItemFactory, check_mongo_calls
|
||||
from xmodule.modulestore import ModuleStoreEnum # lint-amnesty, pylint: disable=wrong-import-order
|
||||
from xmodule.modulestore.django import modulestore # lint-amnesty, pylint: disable=wrong-import-order
|
||||
from xmodule.modulestore.tests.django_utils import ModuleStoreTestCase # lint-amnesty, pylint: disable=wrong-import-order
|
||||
from xmodule.modulestore.tests.factories import CourseFactory, ItemFactory, check_mongo_calls # lint-amnesty, pylint: disable=wrong-import-order
|
||||
|
||||
from .. import DEFAULT_FIELDS, OPTIONAL_FIELDS, PathItem
|
||||
from ..models import Bookmark, XBlockCache, parse_path_data
|
||||
|
||||
@@ -13,7 +13,7 @@ from django.urls import reverse
|
||||
from rest_framework.test import APIClient
|
||||
|
||||
from openedx.core.djangolib.testing.utils import skip_unless_lms
|
||||
from xmodule.modulestore import ModuleStoreEnum
|
||||
from xmodule.modulestore import ModuleStoreEnum # lint-amnesty, pylint: disable=wrong-import-order
|
||||
|
||||
from .test_api import BookmarkApiEventTestMixin
|
||||
from .test_models import BookmarksTestsBase
|
||||
|
||||
@@ -27,7 +27,7 @@ from openedx.core.lib.api.authentication import BearerAuthentication
|
||||
from openedx.core.djangoapps.bookmarks.api import BookmarksLimitReachedError
|
||||
from openedx.core.lib.api.permissions import IsUserInUrl
|
||||
from openedx.core.lib.url_utils import unquote_slashes
|
||||
from xmodule.modulestore.exceptions import ItemNotFoundError
|
||||
from xmodule.modulestore.exceptions import ItemNotFoundError # lint-amnesty, pylint: disable=wrong-import-order
|
||||
|
||||
from . import DEFAULT_FIELDS, OPTIONAL_FIELDS, api
|
||||
from .serializers import BookmarkSerializer
|
||||
|
||||
@@ -9,8 +9,8 @@ from django.core.management import call_command
|
||||
from openedx.core.djangoapps.catalog.tests.factories import CourseRunFactory
|
||||
from openedx.core.djangoapps.catalog.management.commands.sync_course_runs import Command as sync_command
|
||||
from openedx.core.djangoapps.content.course_overviews.models import CourseOverview
|
||||
from xmodule.modulestore.tests.django_utils import ModuleStoreTestCase
|
||||
from xmodule.modulestore.tests.factories import CourseFactory
|
||||
from xmodule.modulestore.tests.django_utils import ModuleStoreTestCase # lint-amnesty, pylint: disable=wrong-import-order
|
||||
from xmodule.modulestore.tests.factories import CourseFactory # lint-amnesty, pylint: disable=wrong-import-order
|
||||
|
||||
COMMAND_MODULE = 'openedx.core.djangoapps.catalog.management.commands.sync_course_runs'
|
||||
|
||||
|
||||
@@ -11,9 +11,9 @@ from opaque_keys.edx.keys import CourseKey
|
||||
|
||||
from openedx.core.djangoapps.ccxcon import api as ccxconapi
|
||||
from common.djangoapps.student.tests.factories import AdminFactory
|
||||
from xmodule.modulestore.django import modulestore
|
||||
from xmodule.modulestore.tests.django_utils import TEST_DATA_SPLIT_MODULESTORE, SharedModuleStoreTestCase
|
||||
from xmodule.modulestore.tests.factories import CourseFactory, ItemFactory
|
||||
from xmodule.modulestore.django import modulestore # lint-amnesty, pylint: disable=wrong-import-order
|
||||
from xmodule.modulestore.tests.django_utils import TEST_DATA_SPLIT_MODULESTORE, SharedModuleStoreTestCase # lint-amnesty, pylint: disable=wrong-import-order
|
||||
from xmodule.modulestore.tests.factories import CourseFactory, ItemFactory # lint-amnesty, pylint: disable=wrong-import-order
|
||||
|
||||
from .factories import CcxConFactory
|
||||
|
||||
|
||||
@@ -113,7 +113,7 @@ from openedx.core.lib.blockstore_api import (
|
||||
)
|
||||
from openedx.core.djangolib import blockstore_cache
|
||||
from openedx.core.djangolib.blockstore_cache import BundleCache
|
||||
from xmodule.modulestore.django import modulestore
|
||||
from xmodule.modulestore.django import modulestore # lint-amnesty, pylint: disable=wrong-import-order
|
||||
|
||||
from . import tasks
|
||||
|
||||
|
||||
@@ -5,7 +5,7 @@ Helper code for working with Blockstore bundles that contain OLX
|
||||
import dateutil.parser
|
||||
import logging # lint-amnesty, pylint: disable=wrong-import-order
|
||||
|
||||
from functools import lru_cache
|
||||
from functools import lru_cache # lint-amnesty, pylint: disable=wrong-import-order
|
||||
from opaque_keys.edx.locator import BundleDefinitionLocator, LibraryUsageLocatorV2
|
||||
from xblock.core import XBlock
|
||||
from xblock.plugin import PluginMissingError
|
||||
|
||||
@@ -8,8 +8,8 @@ from django.conf import settings
|
||||
from django.dispatch import receiver
|
||||
|
||||
from lms.djangoapps.grades.api import signals as grades_signals
|
||||
from opaque_keys import InvalidKeyError
|
||||
from opaque_keys.edx.locator import LibraryUsageLocatorV2
|
||||
from opaque_keys import InvalidKeyError # lint-amnesty, pylint: disable=wrong-import-order
|
||||
from opaque_keys.edx.locator import LibraryUsageLocatorV2 # lint-amnesty, pylint: disable=wrong-import-order
|
||||
|
||||
from .models import LtiGradedResource
|
||||
|
||||
|
||||
@@ -26,7 +26,7 @@ from openedx.core.djangoapps.xblock import api as xblock_api
|
||||
from openedx.core.djangolib.testing.utils import skip_unless_lms, skip_unless_cms
|
||||
from openedx.core.lib import blockstore_api
|
||||
from common.djangoapps.student.tests.factories import UserFactory
|
||||
from xmodule.unit_block import UnitBlock
|
||||
from xmodule.unit_block import UnitBlock # lint-amnesty, pylint: disable=wrong-import-order
|
||||
|
||||
|
||||
class ContentLibraryContentTestMixin:
|
||||
|
||||
Reference in New Issue
Block a user