Applied pylint-amnesty to xblock_django
This commit is contained in:
@@ -7,7 +7,7 @@ from config_models.admin import ConfigurationModelAdmin, KeyedConfigurationModel
|
||||
from django.contrib import admin
|
||||
from django.utils.translation import ugettext_lazy as _
|
||||
|
||||
from common.djangoapps.xblock_django.models import XBlockConfiguration, XBlockStudioConfiguration, XBlockStudioConfigurationFlag
|
||||
from common.djangoapps.xblock_django.models import XBlockConfiguration, XBlockStudioConfiguration, XBlockStudioConfigurationFlag # lint-amnesty, pylint: disable=line-too-long
|
||||
|
||||
|
||||
class XBlockConfigurationAdmin(KeyedConfigurationModelAdmin):
|
||||
|
||||
@@ -7,7 +7,7 @@ import six
|
||||
|
||||
from openedx.core.djangolib.testing.utils import CacheIsolationTestCase
|
||||
from common.djangoapps.xblock_django.api import authorable_xblocks, deprecated_xblocks, disabled_xblocks
|
||||
from common.djangoapps.xblock_django.models import XBlockConfiguration, XBlockStudioConfiguration, XBlockStudioConfigurationFlag
|
||||
from common.djangoapps.xblock_django.models import XBlockConfiguration, XBlockStudioConfiguration, XBlockStudioConfigurationFlag # lint-amnesty, pylint: disable=line-too-long
|
||||
|
||||
|
||||
class XBlockSupportTestCase(CacheIsolationTestCase):
|
||||
@@ -15,7 +15,7 @@ class XBlockSupportTestCase(CacheIsolationTestCase):
|
||||
Tests for XBlock Support methods.
|
||||
"""
|
||||
def setUp(self):
|
||||
super(XBlockSupportTestCase, self).setUp()
|
||||
super(XBlockSupportTestCase, self).setUp() # lint-amnesty, pylint: disable=super-with-arguments
|
||||
|
||||
# Set up XBlockConfigurations for disabled and deprecated states
|
||||
block_config = [
|
||||
|
||||
@@ -26,7 +26,7 @@ class UserServiceTestCase(TestCase):
|
||||
Tests for the DjangoXBlockUserService.
|
||||
"""
|
||||
def setUp(self):
|
||||
super(UserServiceTestCase, self).setUp()
|
||||
super(UserServiceTestCase, self).setUp() # lint-amnesty, pylint: disable=super-with-arguments
|
||||
self.user = UserFactory(username="tester", email="test@tester.com")
|
||||
self.user.profile.name = "Test Tester"
|
||||
set_user_preference(self.user, 'pref-lang', 'en')
|
||||
|
||||
@@ -3,7 +3,7 @@ Support for converting a django user to an XBlock user
|
||||
"""
|
||||
|
||||
|
||||
from django.contrib.auth.models import User
|
||||
from django.contrib.auth.models import User # lint-amnesty, pylint: disable=imported-auth-user
|
||||
from opaque_keys.edx.keys import CourseKey
|
||||
from xblock.reference.user_service import UserService, XBlockUser
|
||||
|
||||
@@ -24,7 +24,7 @@ class DjangoXBlockUserService(UserService):
|
||||
A user service that converts Django users to XBlockUser
|
||||
"""
|
||||
def __init__(self, django_user, **kwargs):
|
||||
super(DjangoXBlockUserService, self).__init__(**kwargs)
|
||||
super(DjangoXBlockUserService, self).__init__(**kwargs) # lint-amnesty, pylint: disable=super-with-arguments
|
||||
self._django_user = django_user
|
||||
if self._django_user:
|
||||
self._django_user.user_is_staff = kwargs.get('user_is_staff', False)
|
||||
|
||||
Reference in New Issue
Block a user