Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
E
edx-platform
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
edx
edx-platform
Commits
ba8fd1c2
Commit
ba8fd1c2
authored
Jul 10, 2015
by
Sarina Canelake
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Eliminate instances of `unused-import` Pylint violation
parent
4a1e6172
Hide whitespace changes
Inline
Side-by-side
Showing
78 changed files
with
66 additions
and
146 deletions
+66
-146
cms/djangoapps/contentstore/features/checklists.py
+0
-1
cms/djangoapps/contentstore/features/course-outline.py
+1
-1
cms/djangoapps/contentstore/features/course-settings.py
+1
-2
cms/djangoapps/contentstore/features/grading.py
+1
-1
cms/djangoapps/contentstore/views/library.py
+0
-1
cms/djangoapps/contentstore/views/preview.py
+0
-1
cms/djangoapps/contentstore/views/tabs.py
+0
-1
common/djangoapps/external_auth/views.py
+1
-1
common/djangoapps/monitoring/startup.py
+1
-1
common/djangoapps/performance/tests/test_logs.py
+0
-2
common/djangoapps/student/helpers.py
+1
-5
common/djangoapps/student/tests/test_email.py
+2
-2
common/djangoapps/student/tests/test_login_registration_forms.py
+0
-2
common/djangoapps/student/tests/test_verification_status.py
+1
-1
common/djangoapps/student/tests/tests.py
+6
-4
common/djangoapps/student/views.py
+2
-7
common/djangoapps/third_party_auth/pipeline.py
+0
-3
common/djangoapps/third_party_auth/tests/specs/base.py
+0
-1
common/djangoapps/third_party_auth/tests/specs/test_google.py
+0
-1
common/djangoapps/third_party_auth/tests/specs/test_linkedin.py
+0
-1
common/djangoapps/third_party_auth/tests/test_pipeline.py
+1
-1
common/djangoapps/track/models.py
+1
-0
common/djangoapps/track/views/tests/test_views.py
+0
-4
common/lib/safe_lxml/safe_lxml/etree.py
+1
-1
common/lib/xmodule/xmodule/discussion_module.py
+0
-1
common/lib/xmodule/xmodule/modulestore/tests/factories.py
+1
-3
common/lib/xmodule/xmodule/modulestore/tests/test_mixed_modulestore.py
+0
-1
common/lib/xmodule/xmodule/modulestore/tests/test_xml_importer.py
+0
-1
common/lib/xmodule/xmodule/video_module/video_xfields.py
+0
-1
common/lib/xmodule/xmodule/wrapper_module.py
+0
-1
common/test/acceptance/pages/lms/dashboard.py
+0
-1
common/test/acceptance/pages/lms/find_courses.py
+0
-1
common/test/acceptance/pages/lms/pay_and_verify.py
+2
-3
common/test/acceptance/pages/lms/track_selection.py
+1
-5
common/test/acceptance/pages/studio/overview.py
+0
-1
common/test/acceptance/performance/test_lms_performance.py
+1
-1
common/test/acceptance/tests/lms/test_lms.py
+0
-1
common/test/acceptance/tests/lms/test_lms_course_discovery.py
+0
-2
common/test/acceptance/tests/lms/test_lms_courseware_search.py
+0
-1
common/test/acceptance/tests/lms/test_lms_edxnotes.py
+3
-1
common/test/acceptance/tests/lms/test_lms_user_preview.py
+0
-1
common/test/acceptance/tests/studio/test_studio_home.py
+0
-1
common/test/acceptance/tests/studio/test_studio_library.py
+0
-1
common/test/acceptance/tests/studio/test_studio_settings.py
+0
-1
common/test/acceptance/tests/studio/test_studio_split_test.py
+0
-1
common/test/acceptance/tests/test_annotatable.py
+0
-3
lms/djangoapps/ccx/views.py
+10
-12
lms/djangoapps/commerce/urls.py
+1
-1
lms/djangoapps/courseware/features/gst.py
+1
-2
lms/djangoapps/courseware/features/video.py
+1
-1
lms/djangoapps/courseware/features/word_cloud.py
+0
-3
lms/djangoapps/courseware/views.py
+0
-1
lms/djangoapps/discussion_api/forms.py
+0
-1
lms/djangoapps/django_comment_client/forum/tests.py
+0
-1
lms/djangoapps/django_comment_client/permissions.py
+0
-1
lms/djangoapps/instructor_task/tests/test_integration.py
+6
-3
lms/djangoapps/lti_provider/views.py
+0
-3
lms/djangoapps/mobile_api/course_info/views.py
+1
-1
lms/djangoapps/mobile_api/users/serializers.py
+0
-1
lms/djangoapps/shoppingcart/tests/test_views.py
+0
-1
lms/djangoapps/shoppingcart/views.py
+0
-1
lms/djangoapps/student_account/test/test_views.py
+1
-3
lms/djangoapps/student_profile/views.py
+0
-2
lms/djangoapps/verify_student/models.py
+1
-1
lms/djangoapps/verify_student/tests/test_models.py
+1
-2
lms/djangoapps/verify_student/tests/test_views.py
+1
-3
lms/lib/courseware_search/lms_result_processor.py
+0
-2
lms/tests.py
+0
-1
lms/urls.py
+0
-1
openedx/core/djangoapps/course_groups/tests/test_partition_scheme.py
+2
-3
openedx/core/djangoapps/course_groups/views.py
+1
-1
openedx/core/djangoapps/user_api/forms.py
+1
-0
openedx/core/djangoapps/user_api/management/tests/test_email_opt_in_list.py
+1
-4
openedx/core/djangoapps/user_api/models.py
+1
-1
openedx/core/djangoapps/user_api/tests/test_models.py
+3
-2
pavelib/paver_tests/test_paver_get_quality_reports.py
+4
-7
pavelib/tests.py
+1
-1
pavelib/utils/test/suites/nose_suite.py
+0
-1
No files found.
cms/djangoapps/contentstore/features/checklists.py
View file @
ba8fd1c2
...
@@ -3,7 +3,6 @@
...
@@ -3,7 +3,6 @@
from
lettuce
import
world
,
step
from
lettuce
import
world
,
step
from
nose.tools
import
assert_true
,
assert_equal
# pylint: disable=no-name-in-module
from
nose.tools
import
assert_true
,
assert_equal
# pylint: disable=no-name-in-module
from
terrain.steps
import
reload_the_page
from
selenium.common.exceptions
import
StaleElementReferenceException
from
selenium.common.exceptions
import
StaleElementReferenceException
...
...
cms/djangoapps/contentstore/features/course-outline.py
View file @
ba8fd1c2
...
@@ -3,7 +3,7 @@
...
@@ -3,7 +3,7 @@
from
lettuce
import
world
,
step
from
lettuce
import
world
,
step
from
common
import
*
from
common
import
*
from
nose.tools
import
assert_true
,
assert_false
,
assert_equal
# pylint: disable=no-name-in-module
from
nose.tools
import
assert_true
,
assert_false
# pylint: disable=no-name-in-module
from
logging
import
getLogger
from
logging
import
getLogger
logger
=
getLogger
(
__name__
)
logger
=
getLogger
(
__name__
)
...
...
cms/djangoapps/contentstore/features/course-settings.py
View file @
ba8fd1c2
...
@@ -2,12 +2,11 @@
...
@@ -2,12 +2,11 @@
# pylint: disable=redefined-outer-name
# pylint: disable=redefined-outer-name
from
lettuce
import
world
,
step
from
lettuce
import
world
,
step
from
terrain.steps
import
reload_the_page
from
selenium.webdriver.common.keys
import
Keys
from
selenium.webdriver.common.keys
import
Keys
from
common
import
type_in_codemirror
,
upload_file
from
common
import
type_in_codemirror
,
upload_file
from
django.conf
import
settings
from
django.conf
import
settings
from
nose.tools
import
assert_true
,
assert_false
,
assert_equal
# pylint: disable=no-name-in-module
from
nose.tools
import
assert_true
,
assert_false
# pylint: disable=no-name-in-module
TEST_ROOT
=
settings
.
COMMON_TEST_DATA_ROOT
TEST_ROOT
=
settings
.
COMMON_TEST_DATA_ROOT
...
...
cms/djangoapps/contentstore/features/grading.py
View file @
ba8fd1c2
...
@@ -6,7 +6,7 @@ from common import *
...
@@ -6,7 +6,7 @@ from common import *
from
terrain.steps
import
reload_the_page
from
terrain.steps
import
reload_the_page
from
selenium.common.exceptions
import
InvalidElementStateException
from
selenium.common.exceptions
import
InvalidElementStateException
from
contentstore.utils
import
reverse_course_url
from
contentstore.utils
import
reverse_course_url
from
nose.tools
import
assert_in
,
assert_
not_in
,
assert_
equal
,
assert_not_equal
# pylint: disable=no-name-in-module
from
nose.tools
import
assert_in
,
assert_equal
,
assert_not_equal
# pylint: disable=no-name-in-module
@step
(
u'I am viewing the grading settings'
)
@step
(
u'I am viewing the grading settings'
)
...
...
cms/djangoapps/contentstore/views/library.py
View file @
ba8fd1c2
...
@@ -31,7 +31,6 @@ from student.auth import (
...
@@ -31,7 +31,6 @@ from student.auth import (
STUDIO_VIEW_USERS
,
STUDIO_EDIT_ROLES
,
get_user_permissions
,
has_studio_read_access
,
has_studio_write_access
STUDIO_VIEW_USERS
,
STUDIO_EDIT_ROLES
,
get_user_permissions
,
has_studio_read_access
,
has_studio_write_access
)
)
from
student.roles
import
CourseInstructorRole
,
CourseStaffRole
,
LibraryUserRole
from
student.roles
import
CourseInstructorRole
,
CourseStaffRole
,
LibraryUserRole
from
student
import
auth
from
util.json_request
import
expect_json
,
JsonResponse
,
JsonResponseBadRequest
from
util.json_request
import
expect_json
,
JsonResponse
,
JsonResponseBadRequest
__all__
=
[
'library_handler'
,
'manage_library_users'
]
__all__
=
[
'library_handler'
,
'manage_library_users'
]
...
...
cms/djangoapps/contentstore/views/preview.py
View file @
ba8fd1c2
...
@@ -19,7 +19,6 @@ from xmodule.services import SettingsService
...
@@ -19,7 +19,6 @@ from xmodule.services import SettingsService
from
xmodule.modulestore.django
import
modulestore
,
ModuleI18nService
from
xmodule.modulestore.django
import
modulestore
,
ModuleI18nService
from
xmodule.mixin
import
wrap_with_license
from
xmodule.mixin
import
wrap_with_license
from
opaque_keys.edx.keys
import
UsageKey
from
opaque_keys.edx.keys
import
UsageKey
from
opaque_keys.edx.locator
import
LibraryUsageLocator
from
xmodule.x_module
import
ModuleSystem
from
xmodule.x_module
import
ModuleSystem
from
xblock.runtime
import
KvsFieldData
from
xblock.runtime
import
KvsFieldData
from
xblock.django.request
import
webob_to_django_response
,
django_to_webob_request
from
xblock.django.request
import
webob_to_django_response
,
django_to_webob_request
...
...
cms/djangoapps/contentstore/views/tabs.py
View file @
ba8fd1c2
...
@@ -5,7 +5,6 @@ from student.auth import has_course_author_access
...
@@ -5,7 +5,6 @@ from student.auth import has_course_author_access
from
util.json_request
import
expect_json
,
JsonResponse
from
util.json_request
import
expect_json
,
JsonResponse
from
django.http
import
HttpResponseNotFound
from
django.http
import
HttpResponseNotFound
from
django.conf
import
settings
from
django.contrib.auth.decorators
import
login_required
from
django.contrib.auth.decorators
import
login_required
from
django.core.exceptions
import
PermissionDenied
from
django.core.exceptions
import
PermissionDenied
from
django.views.decorators.csrf
import
ensure_csrf_cookie
from
django.views.decorators.csrf
import
ensure_csrf_cookie
...
...
common/djangoapps/external_auth/views.py
View file @
ba8fd1c2
...
@@ -25,7 +25,7 @@ if settings.FEATURES.get('AUTH_USE_CAS'):
...
@@ -25,7 +25,7 @@ if settings.FEATURES.get('AUTH_USE_CAS'):
from
student.helpers
import
get_next_url_for_login_page
from
student.helpers
import
get_next_url_for_login_page
from
student.models
import
UserProfile
from
student.models
import
UserProfile
from
django.http
import
HttpResponse
,
HttpResponseRedirect
,
HttpRe
quest
,
HttpRe
sponseForbidden
from
django.http
import
HttpResponse
,
HttpResponseRedirect
,
HttpResponseForbidden
from
django.utils.http
import
urlquote
,
is_safe_url
from
django.utils.http
import
urlquote
,
is_safe_url
from
django.shortcuts
import
redirect
from
django.shortcuts
import
redirect
from
django.utils.translation
import
ugettext
as
_
from
django.utils.translation
import
ugettext
as
_
...
...
common/djangoapps/monitoring/startup.py
View file @
ba8fd1c2
# Register signal handlers
# Register signal handlers
# pylint: disable=unused-import
s
# pylint: disable=unused-import
import
signals
import
signals
import
exceptions
import
exceptions
common/djangoapps/performance/tests/test_logs.py
View file @
ba8fd1c2
...
@@ -2,8 +2,6 @@
...
@@ -2,8 +2,6 @@
import
datetime
import
datetime
import
dateutil
import
dateutil
import
json
import
json
import
mock
import
unittest
import
logging
import
logging
from
StringIO
import
StringIO
from
StringIO
import
StringIO
...
...
common/djangoapps/student/helpers.py
View file @
ba8fd1c2
"""Helpers for the student app. """
"""Helpers for the student app. """
import
time
from
datetime
import
datetime
from
datetime
import
datetime
import
urllib
import
urllib
from
pytz
import
UTC
from
pytz
import
UTC
from
django.utils.http
import
cookie_date
from
django.conf
import
settings
from
django.core.urlresolvers
import
reverse
,
NoReverseMatch
from
django.core.urlresolvers
import
reverse
,
NoReverseMatch
import
third_party_auth
import
third_party_auth
from
verify_student.models
import
SoftwareSecurePhotoVerification
# pylint: disable=
F0401
from
verify_student.models
import
SoftwareSecurePhotoVerification
# pylint: disable=
import-error
from
course_modes.models
import
CourseMode
from
course_modes.models
import
CourseMode
...
...
common/djangoapps/student/tests/test_email.py
View file @
ba8fd1c2
...
@@ -11,11 +11,11 @@ from student.views import (
...
@@ -11,11 +11,11 @@ from student.views import (
from
student.models
import
UserProfile
,
PendingEmailChange
from
student.models
import
UserProfile
,
PendingEmailChange
from
django.core.urlresolvers
import
reverse
from
django.core.urlresolvers
import
reverse
from
django.core
import
mail
from
django.core
import
mail
from
django.contrib.auth.models
import
User
,
AnonymousUser
from
django.contrib.auth.models
import
User
from
django.test
import
TestCase
,
TransactionTestCase
from
django.test
import
TestCase
,
TransactionTestCase
from
django.test.client
import
RequestFactory
from
django.test.client
import
RequestFactory
from
mock
import
Mock
,
patch
from
mock
import
Mock
,
patch
from
django.http
import
Http
404
,
Http
Response
from
django.http
import
HttpResponse
from
django.conf
import
settings
from
django.conf
import
settings
from
edxmako.shortcuts
import
render_to_string
from
edxmako.shortcuts
import
render_to_string
from
edxmako.tests
import
mako_middleware_process_request
from
edxmako.tests
import
mako_middleware_process_request
...
...
common/djangoapps/student/tests/test_login_registration_forms.py
View file @
ba8fd1c2
"""Tests for the login and registration form rendering. """
"""Tests for the login and registration form rendering. """
import
urllib
import
urllib
import
unittest
import
unittest
from
collections
import
OrderedDict
import
ddt
import
ddt
from
mock
import
patch
from
mock
import
patch
...
@@ -10,7 +9,6 @@ from django.core.urlresolvers import reverse
...
@@ -10,7 +9,6 @@ from django.core.urlresolvers import reverse
from
util.testing
import
UrlResetMixin
from
util.testing
import
UrlResetMixin
from
xmodule.modulestore.tests.factories
import
CourseFactory
from
xmodule.modulestore.tests.factories
import
CourseFactory
from
student.tests.factories
import
CourseModeFactory
from
third_party_auth.tests.testutil
import
ThirdPartyAuthTestMixin
from
third_party_auth.tests.testutil
import
ThirdPartyAuthTestMixin
from
xmodule.modulestore.tests.django_utils
import
ModuleStoreTestCase
from
xmodule.modulestore.tests.django_utils
import
ModuleStoreTestCase
...
...
common/djangoapps/student/tests/test_verification_status.py
View file @
ba8fd1c2
...
@@ -20,7 +20,7 @@ from xmodule.modulestore.tests.factories import CourseFactory
...
@@ -20,7 +20,7 @@ from xmodule.modulestore.tests.factories import CourseFactory
from
xmodule.modulestore.tests.django_utils
import
ModuleStoreTestCase
from
xmodule.modulestore.tests.django_utils
import
ModuleStoreTestCase
from
student.tests.factories
import
UserFactory
,
CourseEnrollmentFactory
from
student.tests.factories
import
UserFactory
,
CourseEnrollmentFactory
from
course_modes.tests.factories
import
CourseModeFactory
from
course_modes.tests.factories
import
CourseModeFactory
from
verify_student.models
import
SoftwareSecurePhotoVerification
# pylint: disable=
F0401
from
verify_student.models
import
SoftwareSecurePhotoVerification
# pylint: disable=
import-error
from
util.testing
import
UrlResetMixin
from
util.testing
import
UrlResetMixin
...
...
common/djangoapps/student/tests/tests.py
View file @
ba8fd1c2
...
@@ -10,18 +10,20 @@ import ddt
...
@@ -10,18 +10,20 @@ import ddt
from
django.conf
import
settings
from
django.conf
import
settings
from
django.contrib.auth.models
import
User
,
AnonymousUser
from
django.contrib.auth.models
import
User
,
AnonymousUser
from
django.contrib.sessions.middleware
import
SessionMiddleware
from
django.core.urlresolvers
import
reverse
from
django.core.urlresolvers
import
reverse
from
django.test
import
TestCase
from
django.test
import
TestCase
from
django.test.client
import
RequestFactory
,
Client
from
django.test.client
import
Client
from
mock
import
Mock
,
patch
from
mock
import
Mock
,
patch
from
opaque_keys.edx.locations
import
SlashSeparatedCourseKey
from
opaque_keys.edx.locations
import
SlashSeparatedCourseKey
from
student.models
import
(
from
student.models
import
(
anonymous_id_for_user
,
user_by_anonymous_id
,
CourseEnrollment
,
unique_id_for_user
,
LinkedInAddToProfileConfiguration
anonymous_id_for_user
,
user_by_anonymous_id
,
CourseEnrollment
,
unique_id_for_user
,
LinkedInAddToProfileConfiguration
)
)
from
student.views
import
(
process_survey_link
,
_cert_info
,
from
student.views
import
(
change_enrollment
,
complete_course_mode_info
)
process_survey_link
,
_cert_info
,
complete_course_mode_info
,
)
from
student.tests.factories
import
UserFactory
,
CourseModeFactory
from
student.tests.factories
import
UserFactory
,
CourseModeFactory
from
util.testing
import
EventTestMixin
from
util.testing
import
EventTestMixin
from
util.model_utils
import
USER_SETTINGS_CHANGED_EVENT_NAME
from
util.model_utils
import
USER_SETTINGS_CHANGED_EVENT_NAME
...
...
common/djangoapps/student/views.py
View file @
ba8fd1c2
...
@@ -6,7 +6,6 @@ import logging
...
@@ -6,7 +6,6 @@ import logging
import
uuid
import
uuid
import
json
import
json
import
warnings
import
warnings
from
datetime
import
timedelta
from
collections
import
defaultdict
from
collections
import
defaultdict
from
pytz
import
UTC
from
pytz
import
UTC
from
requests
import
HTTPError
from
requests
import
HTTPError
...
@@ -26,9 +25,8 @@ from django.db import IntegrityError, transaction
...
@@ -26,9 +25,8 @@ from django.db import IntegrityError, transaction
from
django.http
import
(
HttpResponse
,
HttpResponseBadRequest
,
HttpResponseForbidden
,
from
django.http
import
(
HttpResponse
,
HttpResponseBadRequest
,
HttpResponseForbidden
,
HttpResponseServerError
,
Http404
)
HttpResponseServerError
,
Http404
)
from
django.shortcuts
import
redirect
from
django.shortcuts
import
redirect
from
django.utils
import
timezone
from
django.utils.translation
import
ungettext
from
django.utils.translation
import
ungettext
from
django.utils.http
import
cookie_date
,
base36_to_int
from
django.utils.http
import
base36_to_int
from
django.utils.translation
import
ugettext
as
_
,
get_language
from
django.utils.translation
import
ugettext
as
_
,
get_language
from
django.views.decorators.cache
import
never_cache
from
django.views.decorators.cache
import
never_cache
from
django.views.decorators.csrf
import
csrf_exempt
,
ensure_csrf_cookie
from
django.views.decorators.csrf
import
csrf_exempt
,
ensure_csrf_cookie
...
@@ -49,7 +47,7 @@ from edxmako.shortcuts import render_to_response, render_to_string
...
@@ -49,7 +47,7 @@ from edxmako.shortcuts import render_to_response, render_to_string
from
course_modes.models
import
CourseMode
from
course_modes.models
import
CourseMode
from
shoppingcart.api
import
order_history
from
shoppingcart.api
import
order_history
from
student.models
import
(
from
student.models
import
(
Registration
,
UserProfile
,
PendingNameChange
,
Registration
,
UserProfile
,
PendingEmailChange
,
CourseEnrollment
,
CourseEnrollmentAttribute
,
unique_id_for_user
,
PendingEmailChange
,
CourseEnrollment
,
CourseEnrollmentAttribute
,
unique_id_for_user
,
CourseEnrollmentAllowed
,
UserStanding
,
LoginFailures
,
CourseEnrollmentAllowed
,
UserStanding
,
LoginFailures
,
create_comments_service_user
,
PasswordHistory
,
UserSignupSource
,
create_comments_service_user
,
PasswordHistory
,
UserSignupSource
,
...
@@ -60,10 +58,8 @@ from verify_student.models import SoftwareSecurePhotoVerification # pylint: dis
...
@@ -60,10 +58,8 @@ from verify_student.models import SoftwareSecurePhotoVerification # pylint: dis
from
certificates.models
import
CertificateStatuses
,
certificate_status_for_student
from
certificates.models
import
CertificateStatuses
,
certificate_status_for_student
from
certificates.api
import
(
# pylint: disable=import-error
from
certificates.api
import
(
# pylint: disable=import-error
get_certificate_url
,
get_certificate_url
,
get_active_web_certificate
,
has_html_certificates_enabled
,
has_html_certificates_enabled
,
)
)
from
dark_lang.models
import
DarkLangConfig
from
xmodule.modulestore.django
import
modulestore
from
xmodule.modulestore.django
import
modulestore
from
opaque_keys
import
InvalidKeyError
from
opaque_keys
import
InvalidKeyError
...
@@ -86,7 +82,6 @@ from external_auth.login_and_register import (
...
@@ -86,7 +82,6 @@ from external_auth.login_and_register import (
)
)
from
bulk_email.models
import
Optout
,
CourseAuthorization
from
bulk_email.models
import
Optout
,
CourseAuthorization
import
shoppingcart
from
lang_pref
import
LANGUAGE_KEY
from
lang_pref
import
LANGUAGE_KEY
import
track.views
import
track.views
...
...
common/djangoapps/third_party_auth/pipeline.py
View file @
ba8fd1c2
...
@@ -80,9 +80,6 @@ from logging import getLogger
...
@@ -80,9 +80,6 @@ from logging import getLogger
from
.
import
provider
from
.
import
provider
# Note that this lives in openedx, so this dependency should be refactored.
from
openedx.core.djangoapps.user_api.preferences.api
import
update_email_opt_in
# These are the query string params you can pass
# These are the query string params you can pass
# to the URL that starts the authentication process.
# to the URL that starts the authentication process.
...
...
common/djangoapps/third_party_auth/tests/specs/base.py
View file @
ba8fd1c2
"""Base integration test for provider implementations."""
"""Base integration test for provider implementations."""
import
re
import
unittest
import
unittest
import
json
import
json
...
...
common/djangoapps/third_party_auth/tests/specs/test_google.py
View file @
ba8fd1c2
"""Integration tests for Google providers."""
"""Integration tests for Google providers."""
from
third_party_auth
import
provider
from
third_party_auth.tests.specs
import
base
from
third_party_auth.tests.specs
import
base
...
...
common/djangoapps/third_party_auth/tests/specs/test_linkedin.py
View file @
ba8fd1c2
"""Integration tests for LinkedIn providers."""
"""Integration tests for LinkedIn providers."""
from
third_party_auth
import
provider
from
third_party_auth.tests.specs
import
base
from
third_party_auth.tests.specs
import
base
...
...
common/djangoapps/third_party_auth/tests/test_pipeline.py
View file @
ba8fd1c2
...
@@ -2,7 +2,7 @@
...
@@ -2,7 +2,7 @@
import
random
import
random
from
third_party_auth
import
pipeline
,
provider
from
third_party_auth
import
pipeline
from
third_party_auth.tests
import
testutil
from
third_party_auth.tests
import
testutil
import
unittest
import
unittest
...
...
common/djangoapps/track/models.py
View file @
ba8fd1c2
# pylint: disable=unused-import, missing-docstring
from
track.backends.django
import
TrackingLog
from
track.backends.django
import
TrackingLog
common/djangoapps/track/views/tests/test_views.py
View file @
ba8fd1c2
...
@@ -3,18 +3,14 @@
...
@@ -3,18 +3,14 @@
from
mock
import
patch
,
sentinel
from
mock
import
patch
,
sentinel
from
django.contrib.auth.models
import
User
from
django.contrib.auth.models
import
User
from
django.test
import
TestCase
from
django.test.client
import
RequestFactory
from
django.test.client
import
RequestFactory
from
django.test.utils
import
override_settings
from
django.test.utils
import
override_settings
from
eventtracking
import
tracker
from
track
import
views
from
track
import
views
from
track.middleware
import
TrackMiddleware
from
track.middleware
import
TrackMiddleware
from
track.tests
import
EventTrackingTestCase
,
FROZEN_TIME
from
track.tests
import
EventTrackingTestCase
,
FROZEN_TIME
from
openedx.core.lib.tests.assertions.events
import
assert_event_matches
from
openedx.core.lib.tests.assertions.events
import
assert_event_matches
from
datetime
import
datetime
class
TestTrackViews
(
EventTrackingTestCase
):
class
TestTrackViews
(
EventTrackingTestCase
):
...
...
common/lib/safe_lxml/safe_lxml/etree.py
View file @
ba8fd1c2
...
@@ -12,7 +12,7 @@ from lxml.etree import XMLParser as _XMLParser
...
@@ -12,7 +12,7 @@ from lxml.etree import XMLParser as _XMLParser
from
lxml.etree
import
_Element
,
_ElementTree
# pylint: disable=unused-import, no-name-in-module
from
lxml.etree
import
_Element
,
_ElementTree
# pylint: disable=unused-import, no-name-in-module
# This should be imported after lxml.etree so that it overrides the following attributes.
# This should be imported after lxml.etree so that it overrides the following attributes.
from
defusedxml.lxml
import
parse
,
fromstring
,
XML
from
defusedxml.lxml
import
parse
,
fromstring
,
XML
# pylint: disable=unused-import
class
XMLParser
(
_XMLParser
):
# pylint: disable=function-redefined
class
XMLParser
(
_XMLParser
):
# pylint: disable=function-redefined
...
...
common/lib/xmodule/xmodule/discussion_module.py
View file @
ba8fd1c2
...
@@ -4,7 +4,6 @@ from xmodule.x_module import XModule
...
@@ -4,7 +4,6 @@ from xmodule.x_module import XModule
from
xmodule.raw_module
import
RawDescriptor
from
xmodule.raw_module
import
RawDescriptor
from
xmodule.editing_module
import
MetadataOnlyEditingDescriptor
from
xmodule.editing_module
import
MetadataOnlyEditingDescriptor
from
xblock.fields
import
String
,
Scope
,
UNIQUE_ID
from
xblock.fields
import
String
,
Scope
,
UNIQUE_ID
from
uuid
import
uuid4
# Make '_' a no-op so we can scrape strings
# Make '_' a no-op so we can scrape strings
_
=
lambda
text
:
text
_
=
lambda
text
:
text
...
...
common/lib/xmodule/xmodule/modulestore/tests/factories.py
View file @
ba8fd1c2
...
@@ -3,8 +3,6 @@ Factories for use in tests of XBlocks.
...
@@ -3,8 +3,6 @@ Factories for use in tests of XBlocks.
"""
"""
import
functools
import
functools
import
inspect
import
pprint
import
pymongo.message
import
pymongo.message
import
threading
import
threading
import
traceback
import
traceback
...
@@ -14,7 +12,7 @@ from uuid import uuid4
...
@@ -14,7 +12,7 @@ from uuid import uuid4
from
factory
import
Factory
,
Sequence
,
lazy_attribute_sequence
,
lazy_attribute
from
factory
import
Factory
,
Sequence
,
lazy_attribute_sequence
,
lazy_attribute
from
factory.containers
import
CyclicDefinitionError
from
factory.containers
import
CyclicDefinitionError
from
mock
import
Mock
,
patch
from
mock
import
patch
from
nose.tools
import
assert_less_equal
,
assert_greater_equal
from
nose.tools
import
assert_less_equal
,
assert_greater_equal
import
dogstats_wrapper
as
dog_stats_api
import
dogstats_wrapper
as
dog_stats_api
...
...
common/lib/xmodule/xmodule/modulestore/tests/test_mixed_modulestore.py
View file @
ba8fd1c2
...
@@ -8,7 +8,6 @@ import logging
...
@@ -8,7 +8,6 @@ import logging
import
ddt
import
ddt
import
itertools
import
itertools
import
mimetypes
import
mimetypes
from
unittest
import
skip
from
uuid
import
uuid4
from
uuid
import
uuid4
from
contextlib
import
contextmanager
from
contextlib
import
contextmanager
from
mock
import
patch
from
mock
import
patch
...
...
common/lib/xmodule/xmodule/modulestore/tests/test_xml_importer.py
View file @
ba8fd1c2
...
@@ -3,7 +3,6 @@ Tests for XML importer.
...
@@ -3,7 +3,6 @@ Tests for XML importer.
"""
"""
import
mock
import
mock
from
opaque_keys.edx.locator
import
BlockUsageLocator
,
CourseLocator
from
opaque_keys.edx.locator
import
BlockUsageLocator
,
CourseLocator
from
xblock.core
import
XBlock
from
xblock.fields
import
String
,
Scope
,
ScopeIds
,
List
from
xblock.fields
import
String
,
Scope
,
ScopeIds
,
List
from
xblock.runtime
import
Runtime
,
KvsFieldData
,
DictKeyValueStore
from
xblock.runtime
import
Runtime
,
KvsFieldData
,
DictKeyValueStore
from
xmodule.x_module
import
XModuleMixin
from
xmodule.x_module
import
XModuleMixin
...
...
common/lib/xmodule/xmodule/video_module/video_xfields.py
View file @
ba8fd1c2
...
@@ -6,7 +6,6 @@ import datetime
...
@@ -6,7 +6,6 @@ import datetime
from
xblock.fields
import
Scope
,
String
,
Float
,
Boolean
,
List
,
Dict
,
DateTime
from
xblock.fields
import
Scope
,
String
,
Float
,
Boolean
,
List
,
Dict
,
DateTime
from
xmodule.fields
import
RelativeTime
from
xmodule.fields
import
RelativeTime
from
xmodule.mixin
import
LicenseMixin
# Make '_' a no-op so we can scrape strings
# Make '_' a no-op so we can scrape strings
_
=
lambda
text
:
text
_
=
lambda
text
:
text
...
...
common/lib/xmodule/xmodule/wrapper_module.py
View file @
ba8fd1c2
...
@@ -2,7 +2,6 @@
...
@@ -2,7 +2,6 @@
# But w/o css delimiters between children
# But w/o css delimiters between children
from
xmodule.vertical_block
import
VerticalBlock
from
xmodule.vertical_block
import
VerticalBlock
from
pkg_resources
import
resource_string
# HACK: This shouldn't be hard-coded to two types
# HACK: This shouldn't be hard-coded to two types
# OBSOLETE: This obsoletes 'type'
# OBSOLETE: This obsoletes 'type'
...
...
common/test/acceptance/pages/lms/dashboard.py
View file @
ba8fd1c2
...
@@ -4,7 +4,6 @@ Student dashboard page.
...
@@ -4,7 +4,6 @@ Student dashboard page.
"""
"""
from
bok_choy.page_object
import
PageObject
from
bok_choy.page_object
import
PageObject
from
bok_choy.promise
import
EmptyPromise
from
.
import
BASE_URL
from
.
import
BASE_URL
...
...
common/test/acceptance/pages/lms/find_courses.py
View file @
ba8fd1c2
...
@@ -3,7 +3,6 @@ Find courses page (main page of the LMS).
...
@@ -3,7 +3,6 @@ Find courses page (main page of the LMS).
"""
"""
from
bok_choy.page_object
import
PageObject
from
bok_choy.page_object
import
PageObject
from
bok_choy.promise
import
BrokenPromise
from
.
import
BASE_URL
from
.
import
BASE_URL
...
...
common/test/acceptance/pages/lms/pay_and_verify.py
View file @
ba8fd1c2
"""Payment and verification pages"""
"""Payment and verification pages"""
import
re
import
re
from
urllib
import
urlencode
from
bok_choy.page_object
import
PageObject
,
unguarded
from
bok_choy.page_object
import
PageObject
from
bok_choy.promise
import
Promise
,
EmptyPromise
from
bok_choy.promise
import
Promise
from
.
import
BASE_URL
from
.
import
BASE_URL
from
.dashboard
import
DashboardPage
from
.dashboard
import
DashboardPage
...
...
common/test/acceptance/pages/lms/track_selection.py
View file @
ba8fd1c2
"""Track selection page"""
"""Track selection page"""
from
bok_choy.page_object
import
PageObject
from
urllib
import
urlencode
from
bok_choy.page_object
import
PageObject
,
unguarded
from
bok_choy.promise
import
Promise
,
EmptyPromise
from
.
import
BASE_URL
from
.
import
BASE_URL
from
.dashboard
import
DashboardPage
from
.dashboard
import
DashboardPage
from
.pay_and_verify
import
PaymentAndVerificationFlow
from
.pay_and_verify
import
PaymentAndVerificationFlow
...
...
common/test/acceptance/pages/studio/overview.py
View file @
ba8fd1c2
...
@@ -8,7 +8,6 @@ from bok_choy.promise import EmptyPromise
...
@@ -8,7 +8,6 @@ from bok_choy.promise import EmptyPromise
from
selenium.webdriver.support.ui
import
Select
from
selenium.webdriver.support.ui
import
Select
from
selenium.webdriver.common.keys
import
Keys
from
selenium.webdriver.common.keys
import
Keys
from
selenium.webdriver.common.action_chains
import
ActionChains
from
.course_page
import
CoursePage
from
.course_page
import
CoursePage
from
.container
import
ContainerPage
from
.container
import
ContainerPage
...
...
common/test/acceptance/performance/test_lms_performance.py
View file @
ba8fd1c2
"""
"""
Single page performance tests for LMS.
Single page performance tests for LMS.
"""
"""
from
bok_choy.web_app_test
import
WebAppTest
,
with_cache
from
bok_choy.web_app_test
import
with_cache
from
..pages.lms.auto_auth
import
AutoAuthPage
from
..pages.lms.auto_auth
import
AutoAuthPage
from
..pages.lms.courseware
import
CoursewarePage
from
..pages.lms.courseware
import
CoursewarePage
from
..pages.lms.dashboard
import
DashboardPage
from
..pages.lms.dashboard
import
DashboardPage
...
...
common/test/acceptance/tests/lms/test_lms.py
View file @
ba8fd1c2
...
@@ -9,7 +9,6 @@ from unittest import skip
...
@@ -9,7 +9,6 @@ from unittest import skip
from
nose.plugins.attrib
import
attr
from
nose.plugins.attrib
import
attr
from
bok_choy.promise
import
EmptyPromise
from
bok_choy.promise
import
EmptyPromise
from
bok_choy.web_app_test
import
WebAppTest
from
..helpers
import
(
from
..helpers
import
(
UniqueCourseTest
,
UniqueCourseTest
,
EventsTestMixin
,
EventsTestMixin
,
...
...
common/test/acceptance/tests/lms/test_lms_course_discovery.py
View file @
ba8fd1c2
...
@@ -2,9 +2,7 @@
...
@@ -2,9 +2,7 @@
Test course discovery.
Test course discovery.
"""
"""
import
datetime
import
datetime
from
flaky
import
flaky
import
json
import
json
import
os
from
bok_choy.web_app_test
import
WebAppTest
from
bok_choy.web_app_test
import
WebAppTest
from
..helpers
import
remove_file
from
..helpers
import
remove_file
...
...
common/test/acceptance/tests/lms/test_lms_courseware_search.py
View file @
ba8fd1c2
"""
"""
Test courseware search
Test courseware search
"""
"""
import
os
import
json
import
json
from
nose.plugins.attrib
import
attr
from
nose.plugins.attrib
import
attr
...
...
common/test/acceptance/tests/lms/test_lms_edxnotes.py
View file @
ba8fd1c2
import
os
"""
Test LMS Notes
"""
from
uuid
import
uuid4
from
uuid
import
uuid4
from
datetime
import
datetime
from
datetime
import
datetime
from
nose.plugins.attrib
import
attr
from
nose.plugins.attrib
import
attr
...
...
common/test/acceptance/tests/lms/test_lms_user_preview.py
View file @
ba8fd1c2
...
@@ -7,7 +7,6 @@ from ..helpers import UniqueCourseTest, create_user_partition_json
...
@@ -7,7 +7,6 @@ from ..helpers import UniqueCourseTest, create_user_partition_json
from
...pages.studio.auto_auth
import
AutoAuthPage
from
...pages.studio.auto_auth
import
AutoAuthPage
from
...pages.lms.courseware
import
CoursewarePage
from
...pages.lms.courseware
import
CoursewarePage
from
...pages.lms.staff_view
import
StaffPage
from
...pages.lms.staff_view
import
StaffPage
from
...pages.lms.course_nav
import
CourseNavPage
from
...fixtures.course
import
CourseFixture
,
XBlockFixtureDesc
from
...fixtures.course
import
CourseFixture
,
XBlockFixtureDesc
from
xmodule.partitions.partitions
import
Group
from
xmodule.partitions.partitions
import
Group
from
textwrap
import
dedent
from
textwrap
import
dedent
...
...
common/test/acceptance/tests/studio/test_studio_home.py
View file @
ba8fd1c2
...
@@ -3,7 +3,6 @@ Acceptance tests for Home Page (My Courses / My Libraries).
...
@@ -3,7 +3,6 @@ Acceptance tests for Home Page (My Courses / My Libraries).
"""
"""
from
bok_choy.web_app_test
import
WebAppTest
from
bok_choy.web_app_test
import
WebAppTest
from
opaque_keys.edx.locator
import
LibraryLocator
from
opaque_keys.edx.locator
import
LibraryLocator
from
unittest
import
skip
from
...pages.studio.auto_auth
import
AutoAuthPage
from
...pages.studio.auto_auth
import
AutoAuthPage
from
...pages.studio.library
import
LibraryEditPage
from
...pages.studio.library
import
LibraryEditPage
...
...
common/test/acceptance/tests/studio/test_studio_library.py
View file @
ba8fd1c2
...
@@ -2,7 +2,6 @@
...
@@ -2,7 +2,6 @@
Acceptance tests for Content Libraries in Studio
Acceptance tests for Content Libraries in Studio
"""
"""
from
ddt
import
ddt
,
data
from
ddt
import
ddt
,
data
from
unittest
import
skip
from
nose.plugins.attrib
import
attr
from
nose.plugins.attrib
import
attr
from
flaky
import
flaky
from
flaky
import
flaky
...
...
common/test/acceptance/tests/studio/test_studio_settings.py
View file @
ba8fd1c2
...
@@ -14,7 +14,6 @@ from ...pages.studio.settings import SettingsPage
...
@@ -14,7 +14,6 @@ from ...pages.studio.settings import SettingsPage
from
...pages.studio.settings_advanced
import
AdvancedSettingsPage
from
...pages.studio.settings_advanced
import
AdvancedSettingsPage
from
...pages.studio.settings_group_configurations
import
GroupConfigurationsPage
from
...pages.studio.settings_group_configurations
import
GroupConfigurationsPage
from
...pages.lms.courseware
import
CoursewarePage
from
...pages.lms.courseware
import
CoursewarePage
from
unittest
import
skip
from
textwrap
import
dedent
from
textwrap
import
dedent
from
xmodule.partitions.partitions
import
Group
from
xmodule.partitions.partitions
import
Group
...
...
common/test/acceptance/tests/studio/test_studio_split_test.py
View file @
ba8fd1c2
...
@@ -2,7 +2,6 @@
...
@@ -2,7 +2,6 @@
Acceptance tests for Studio related to the split_test module.
Acceptance tests for Studio related to the split_test module.
"""
"""
import
json
import
math
import
math
from
unittest
import
skip
from
unittest
import
skip
from
nose.plugins.attrib
import
attr
from
nose.plugins.attrib
import
attr
...
...
common/test/acceptance/tests/test_annotatable.py
View file @
ba8fd1c2
...
@@ -2,8 +2,6 @@
...
@@ -2,8 +2,6 @@
"""
"""
E2E tests for the LMS.
E2E tests for the LMS.
"""
"""
import
time
from
unittest
import
skip
from
unittest
import
skip
from
.helpers
import
UniqueCourseTest
from
.helpers
import
UniqueCourseTest
...
@@ -11,7 +9,6 @@ from ..pages.studio.auto_auth import AutoAuthPage
...
@@ -11,7 +9,6 @@ from ..pages.studio.auto_auth import AutoAuthPage
from
..pages.lms.courseware
import
CoursewarePage
from
..pages.lms.courseware
import
CoursewarePage
from
..pages.lms.annotation_component
import
AnnotationComponentPage
from
..pages.lms.annotation_component
import
AnnotationComponentPage
from
..fixtures.course
import
CourseFixture
,
XBlockFixtureDesc
from
..fixtures.course
import
CourseFixture
,
XBlockFixtureDesc
from
..fixtures.xqueue
import
XQueueResponseFixture
from
textwrap
import
dedent
from
textwrap
import
dedent
...
...
lms/djangoapps/ccx/views.py
View file @
ba8fd1c2
...
@@ -16,7 +16,6 @@ from django.core.urlresolvers import reverse
...
@@ -16,7 +16,6 @@ from django.core.urlresolvers import reverse
from
django.http
import
(
from
django.http
import
(
HttpResponse
,
HttpResponse
,
HttpResponseForbidden
,
HttpResponseForbidden
,
HttpResponseRedirect
,
)
)
from
django.contrib
import
messages
from
django.contrib
import
messages
from
django.core.exceptions
import
ValidationError
from
django.core.exceptions
import
ValidationError
...
@@ -26,23 +25,22 @@ from django.shortcuts import redirect
...
@@ -26,23 +25,22 @@ from django.shortcuts import redirect
from
django.utils.translation
import
ugettext
as
_
from
django.utils.translation
import
ugettext
as
_
from
django.views.decorators.cache
import
cache_control
from
django.views.decorators.cache
import
cache_control
from
django.views.decorators.csrf
import
ensure_csrf_cookie
from
django.views.decorators.csrf
import
ensure_csrf_cookie
from
django.contrib.auth.decorators
import
login_required
from
django.contrib.auth.models
import
User
from
django.contrib.auth.models
import
User
from
courseware.courses
import
get_course_by_id
# pylint: disable=import-error
from
courseware.courses
import
get_course_by_id
from
courseware.field_overrides
import
disable_overrides
# pylint: disable=import-error
from
courseware.field_overrides
import
disable_overrides
from
courseware.grades
import
iterate_grades_for
# pylint: disable=import-error
from
courseware.grades
import
iterate_grades_for
from
courseware.model_data
import
FieldDataCache
# pylint: disable=import-error
from
courseware.model_data
import
FieldDataCache
from
courseware.module_render
import
get_module_for_descriptor
# pylint: disable=import-error
from
courseware.module_render
import
get_module_for_descriptor
from
edxmako.shortcuts
import
render_to_response
# pylint: disable=import-error
from
edxmako.shortcuts
import
render_to_response
from
opaque_keys.edx.keys
import
CourseKey
from
opaque_keys.edx.keys
import
CourseKey
from
ccx_keys.locator
import
CCXLocator
from
ccx_keys.locator
import
CCXLocator
from
student.roles
import
CourseCcxCoachRole
# pylint: disable=import-error
from
student.roles
import
CourseCcxCoachRole
from
instructor.offline_gradecalc
import
student_grades
# pylint: disable=import-error
from
instructor.offline_gradecalc
import
student_grades
from
instructor.views.api
import
_split_input_list
# pylint: disable=import-error
from
instructor.views.api
import
_split_input_list
from
instructor.views.tools
import
get_student_from_identifier
# pylint: disable=import-error
from
instructor.views.tools
import
get_student_from_identifier
from
.models
import
CustomCourseForEdX
,
CcxMembership
from
.models
import
CustomCourseForEdX
,
CcxMembership
from
.overrides
import
(
from
.overrides
import
(
...
...
lms/djangoapps/commerce/urls.py
View file @
ba8fd1c2
"""
"""
Defines the URL routes for this app.
Defines the URL routes for this app.
"""
"""
from
django.conf.urls
import
patterns
,
url
,
include
from
django.conf.urls
import
patterns
,
url
from
commerce
import
views
from
commerce
import
views
...
...
lms/djangoapps/courseware/features/gst.py
View file @
ba8fd1c2
from
lettuce
import
world
,
steps
from
lettuce
import
world
,
steps
from
nose.tools
import
assert_
in
,
assert_equals
,
assert_true
from
nose.tools
import
assert_
equals
from
common
import
i_am_registered_for_the_course
,
visit_scenario_item
from
common
import
i_am_registered_for_the_course
,
visit_scenario_item
from
problems_setup
import
add_problem_to_course
,
answer_problem
DEFAULT_DATA
=
"""
\
DEFAULT_DATA
=
"""
\
...
...
lms/djangoapps/courseware/features/video.py
View file @
ba8fd1c2
...
@@ -6,7 +6,7 @@ import json
...
@@ -6,7 +6,7 @@ import json
import
os
import
os
import
time
import
time
import
requests
import
requests
from
nose.tools
import
assert_
less
,
assert_
equal
,
assert_true
,
assert_false
from
nose.tools
import
assert_equal
,
assert_true
,
assert_false
from
common
import
i_am_registered_for_the_course
,
visit_scenario_item
from
common
import
i_am_registered_for_the_course
,
visit_scenario_item
from
django.utils.translation
import
ugettext
as
_
from
django.utils.translation
import
ugettext
as
_
from
django.conf
import
settings
from
django.conf
import
settings
...
...
lms/djangoapps/courseware/features/word_cloud.py
View file @
ba8fd1c2
# pylint: disable=missing-docstring
# pylint: disable=missing-docstring
from
time
import
sleep
from
lettuce
import
world
,
step
from
lettuce
import
world
,
step
from
lettuce.django
import
django_url
from
common
import
i_am_registered_for_the_course
,
section_location
,
visit_scenario_item
from
common
import
i_am_registered_for_the_course
,
section_location
,
visit_scenario_item
...
...
lms/djangoapps/courseware/views.py
View file @
ba8fd1c2
...
@@ -7,7 +7,6 @@ import urllib
...
@@ -7,7 +7,6 @@ import urllib
import
json
import
json
import
cgi
import
cgi
from
collections
import
OrderedDict
from
datetime
import
datetime
from
datetime
import
datetime
from
django.utils
import
translation
from
django.utils
import
translation
from
django.utils.translation
import
ugettext
as
_
from
django.utils.translation
import
ugettext
as
_
...
...
lms/djangoapps/discussion_api/forms.py
View file @
ba8fd1c2
...
@@ -5,7 +5,6 @@ from django.core.exceptions import ValidationError
...
@@ -5,7 +5,6 @@ from django.core.exceptions import ValidationError
from
django.forms
import
(
from
django.forms
import
(
BooleanField
,
BooleanField
,
CharField
,
CharField
,
ChoiceField
,
Field
,
Field
,
Form
,
Form
,
IntegerField
,
IntegerField
,
...
...
lms/djangoapps/django_comment_client/forum/tests.py
View file @
ba8fd1c2
...
@@ -2,7 +2,6 @@ import json
...
@@ -2,7 +2,6 @@ import json
import
logging
import
logging
import
ddt
import
ddt
from
django.core
import
cache
from
django.core.urlresolvers
import
reverse
from
django.core.urlresolvers
import
reverse
from
django.http
import
Http404
from
django.http
import
Http404
from
django.test.client
import
Client
,
RequestFactory
from
django.test.client
import
Client
,
RequestFactory
...
...
lms/djangoapps/django_comment_client/permissions.py
View file @
ba8fd1c2
...
@@ -4,7 +4,6 @@ Module for checking permissions with the comment_client backend
...
@@ -4,7 +4,6 @@ Module for checking permissions with the comment_client backend
import
logging
import
logging
from
types
import
NoneType
from
types
import
NoneType
from
django.core
import
cache
from
request_cache.middleware
import
RequestCache
from
request_cache.middleware
import
RequestCache
from
lms.lib.comment_client
import
Thread
from
lms.lib.comment_client
import
Thread
...
...
lms/djangoapps/instructor_task/tests/test_integration.py
View file @
ba8fd1c2
...
@@ -19,7 +19,6 @@ from capa.tests.response_xml_factory import (CodeResponseXMLFactory,
...
@@ -19,7 +19,6 @@ from capa.tests.response_xml_factory import (CodeResponseXMLFactory,
CustomResponseXMLFactory
)
CustomResponseXMLFactory
)
from
xmodule.modulestore.tests.factories
import
ItemFactory
from
xmodule.modulestore.tests.factories
import
ItemFactory
from
xmodule.modulestore
import
ModuleStoreEnum
from
xmodule.modulestore
import
ModuleStoreEnum
from
xmodule.partitions.partitions
import
Group
,
UserPartition
from
courseware.model_data
import
StudentModule
from
courseware.model_data
import
StudentModule
...
@@ -29,8 +28,12 @@ from instructor_task.api import (submit_rescore_problem_for_all_students,
...
@@ -29,8 +28,12 @@ from instructor_task.api import (submit_rescore_problem_for_all_students,
submit_delete_problem_state_for_all_students
)
submit_delete_problem_state_for_all_students
)
from
instructor_task.models
import
InstructorTask
from
instructor_task.models
import
InstructorTask
from
instructor_task.tasks_helper
import
upload_grades_csv
from
instructor_task.tasks_helper
import
upload_grades_csv
from
instructor_task.tests.test_base
import
(
InstructorTaskModuleTestCase
,
TestReportMixin
,
TEST_COURSE_ORG
,
from
instructor_task.tests.test_base
import
(
TEST_COURSE_NUMBER
,
OPTION_1
,
OPTION_2
)
InstructorTaskModuleTestCase
,
TestReportMixin
,
OPTION_1
,
OPTION_2
,
)
from
capa.responsetypes
import
StudentInputError
from
capa.responsetypes
import
StudentInputError
from
lms.djangoapps.lms_xblock.runtime
import
quote_slashes
from
lms.djangoapps.lms_xblock.runtime
import
quote_slashes
...
...
lms/djangoapps/lti_provider/views.py
View file @
ba8fd1c2
...
@@ -3,9 +3,6 @@ LTI Provider view functions
...
@@ -3,9 +3,6 @@ LTI Provider view functions
"""
"""
from
django.conf
import
settings
from
django.conf
import
settings
from
django.contrib.auth.decorators
import
login_required
from
django.contrib.auth.views
import
redirect_to_login
from
django.core.urlresolvers
import
reverse
from
django.http
import
HttpResponseBadRequest
,
HttpResponseForbidden
,
Http404
from
django.http
import
HttpResponseBadRequest
,
HttpResponseForbidden
,
Http404
from
django.views.decorators.csrf
import
csrf_exempt
from
django.views.decorators.csrf
import
csrf_exempt
import
logging
import
logging
...
...
lms/djangoapps/mobile_api/course_info/views.py
View file @
ba8fd1c2
...
@@ -5,7 +5,7 @@ from django.http import Http404
...
@@ -5,7 +5,7 @@ from django.http import Http404
from
rest_framework
import
generics
from
rest_framework
import
generics
from
rest_framework.response
import
Response
from
rest_framework.response
import
Response
from
courseware.courses
import
get_course_
about_section
,
get_course_
info_section_module
from
courseware.courses
import
get_course_info_section_module
from
static_replace
import
make_static_urls_absolute
,
replace_static_urls
from
static_replace
import
make_static_urls_absolute
,
replace_static_urls
from
openedx.core.lib.xblock_utils
import
get_course_update_items
from
openedx.core.lib.xblock_utils
import
get_course_update_items
...
...
lms/djangoapps/mobile_api/users/serializers.py
View file @
ba8fd1c2
...
@@ -4,7 +4,6 @@ Serializer for user API
...
@@ -4,7 +4,6 @@ Serializer for user API
from
rest_framework
import
serializers
from
rest_framework
import
serializers
from
rest_framework.reverse
import
reverse
from
rest_framework.reverse
import
reverse
from
courseware.courses
import
course_image_url
from
student.models
import
CourseEnrollment
,
User
from
student.models
import
CourseEnrollment
,
User
from
certificates.models
import
certificate_status_for_student
,
CertificateStatuses
from
certificates.models
import
certificate_status_for_student
,
CertificateStatuses
...
...
lms/djangoapps/shoppingcart/tests/test_views.py
View file @
ba8fd1c2
...
@@ -12,7 +12,6 @@ from django.conf import settings
...
@@ -12,7 +12,6 @@ from django.conf import settings
from
django.test
import
TestCase
from
django.test
import
TestCase
from
django.test.utils
import
override_settings
from
django.test.utils
import
override_settings
from
django.core.urlresolvers
import
reverse
from
django.core.urlresolvers
import
reverse
from
django.utils.translation
import
ugettext
as
_
from
django.contrib.admin.sites
import
AdminSite
from
django.contrib.admin.sites
import
AdminSite
from
django.contrib.auth.models
import
Group
,
User
from
django.contrib.auth.models
import
Group
,
User
from
django.contrib.messages.storage.fallback
import
FallbackStorage
from
django.contrib.messages.storage.fallback
import
FallbackStorage
...
...
lms/djangoapps/shoppingcart/views.py
View file @
ba8fd1c2
...
@@ -50,7 +50,6 @@ from .processors import (
...
@@ -50,7 +50,6 @@ from .processors import (
)
)
import
json
import
json
from
xmodule_django.models
import
CourseKeyField
from
.decorators
import
enforce_shopping_cart_enabled
from
.decorators
import
enforce_shopping_cart_enabled
...
...
lms/djangoapps/student_account/test/test_views.py
View file @
ba8fd1c2
...
@@ -18,15 +18,13 @@ from django.test import TestCase
...
@@ -18,15 +18,13 @@ from django.test import TestCase
from
django.test.utils
import
override_settings
from
django.test.utils
import
override_settings
from
django.test.client
import
RequestFactory
from
django.test.client
import
RequestFactory
from
embargo.test_utils
import
restrict_course
from
openedx.core.djangoapps.user_api.accounts.api
import
activate_account
,
create_account
from
openedx.core.djangoapps.user_api.accounts.api
import
activate_account
,
create_account
from
openedx.core.djangoapps.user_api.accounts
import
EMAIL_MAX_LENGTH
from
openedx.core.djangoapps.user_api.accounts
import
EMAIL_MAX_LENGTH
from
student.tests.factories
import
CourseModeFactory
,
UserFactory
from
student.tests.factories
import
UserFactory
from
student_account.views
import
account_settings_context
from
student_account.views
import
account_settings_context
from
third_party_auth.tests.testutil
import
simulate_running_pipeline
,
ThirdPartyAuthTestMixin
from
third_party_auth.tests.testutil
import
simulate_running_pipeline
,
ThirdPartyAuthTestMixin
from
util.testing
import
UrlResetMixin
from
util.testing
import
UrlResetMixin
from
xmodule.modulestore.tests.django_utils
import
ModuleStoreTestCase
from
xmodule.modulestore.tests.django_utils
import
ModuleStoreTestCase
from
xmodule.modulestore.tests.factories
import
CourseFactory
@ddt.ddt
@ddt.ddt
...
...
lms/djangoapps/student_profile/views.py
View file @
ba8fd1c2
...
@@ -17,8 +17,6 @@ from openedx.core.djangoapps.user_api.preferences.api import get_user_preference
...
@@ -17,8 +17,6 @@ from openedx.core.djangoapps.user_api.preferences.api import get_user_preference
from
student.models
import
User
from
student.models
import
User
from
microsite_configuration
import
microsite
from
microsite_configuration
import
microsite
from
django.utils.translation
import
ugettext
as
_
@login_required
@login_required
@require_http_methods
([
'GET'
])
@require_http_methods
([
'GET'
])
...
...
lms/djangoapps/verify_student/models.py
View file @
ba8fd1c2
...
@@ -25,7 +25,7 @@ from django.contrib.auth.models import User
...
@@ -25,7 +25,7 @@ from django.contrib.auth.models import User
from
django.core.exceptions
import
ObjectDoesNotExist
from
django.core.exceptions
import
ObjectDoesNotExist
from
django.core.urlresolvers
import
reverse
from
django.core.urlresolvers
import
reverse
from
django.db
import
models
from
django.db
import
models
from
django.utils.translation
import
ugettext
as
_
,
ugettext_lazy
from
django.utils.translation
import
ugettext
as
_
from
boto.s3.connection
import
S3Connection
from
boto.s3.connection
import
S3Connection
from
boto.s3.key
import
Key
from
boto.s3.key
import
Key
...
...
lms/djangoapps/verify_student/tests/test_models.py
View file @
ba8fd1c2
...
@@ -8,8 +8,7 @@ import pytz
...
@@ -8,8 +8,7 @@ import pytz
from
django.conf
import
settings
from
django.conf
import
settings
from
django.db.utils
import
IntegrityError
from
django.db.utils
import
IntegrityError
from
mock
import
patch
from
mock
import
patch
from
nose.tools
import
assert_is_none
,
assert_equals
,
assert_raises
,
assert_true
,
assert_false
# pylint: disable=E0611
from
nose.tools
import
assert_is_none
,
assert_equals
,
assert_raises
,
assert_true
,
assert_false
# pylint: disable=no-name-in-module
from
opaque_keys.edx.locations
import
SlashSeparatedCourseKey
from
student.tests.factories
import
UserFactory
from
student.tests.factories
import
UserFactory
from
xmodule.modulestore.tests.django_utils
import
ModuleStoreTestCase
from
xmodule.modulestore.tests.django_utils
import
ModuleStoreTestCase
...
...
lms/djangoapps/verify_student/tests/test_views.py
View file @
ba8fd1c2
...
@@ -17,7 +17,6 @@ from mock import patch, Mock, ANY
...
@@ -17,7 +17,6 @@ from mock import patch, Mock, ANY
from
django.conf
import
settings
from
django.conf
import
settings
from
django.core.urlresolvers
import
reverse
from
django.core.urlresolvers
import
reverse
from
django.core.exceptions
import
ObjectDoesNotExist
from
django.core
import
mail
from
django.core
import
mail
from
django.test
import
TestCase
from
django.test
import
TestCase
from
django.test.client
import
Client
,
RequestFactory
from
django.test.client
import
Client
,
RequestFactory
...
@@ -33,7 +32,6 @@ from course_modes.tests.factories import CourseModeFactory
...
@@ -33,7 +32,6 @@ from course_modes.tests.factories import CourseModeFactory
from
courseware.url_helpers
import
get_redirect_url
from
courseware.url_helpers
import
get_redirect_url
from
commerce.tests
import
TEST_PAYMENT_DATA
,
TEST_API_URL
,
TEST_API_SIGNING_KEY
from
commerce.tests
import
TEST_PAYMENT_DATA
,
TEST_API_URL
,
TEST_API_SIGNING_KEY
from
embargo.test_utils
import
restrict_course
from
embargo.test_utils
import
restrict_course
from
microsite_configuration
import
microsite
from
openedx.core.djangoapps.user_api.accounts.api
import
get_account_settings
from
openedx.core.djangoapps.user_api.accounts.api
import
get_account_settings
from
shoppingcart.models
import
Order
,
CertificateItem
from
shoppingcart.models
import
Order
,
CertificateItem
from
student.tests.factories
import
UserFactory
,
CourseEnrollmentFactory
from
student.tests.factories
import
UserFactory
,
CourseEnrollmentFactory
...
@@ -42,7 +40,7 @@ from util.date_utils import get_default_time_display
...
@@ -42,7 +40,7 @@ from util.date_utils import get_default_time_display
from
util.testing
import
UrlResetMixin
from
util.testing
import
UrlResetMixin
from
verify_student.views
import
(
from
verify_student.views
import
(
checkout_with_ecommerce_service
,
render_to_response
,
PayAndVerifyView
,
checkout_with_ecommerce_service
,
render_to_response
,
PayAndVerifyView
,
_
send_email
,
_
compose_message_reverification_email
_compose_message_reverification_email
)
)
from
verify_student.models
import
(
from
verify_student.models
import
(
SoftwareSecurePhotoVerification
,
VerificationCheckpoint
,
SoftwareSecurePhotoVerification
,
VerificationCheckpoint
,
...
...
lms/lib/courseware_search/lms_result_processor.py
View file @
ba8fd1c2
...
@@ -4,12 +4,10 @@ This file contains implementation override of SearchResultProcessor which will a
...
@@ -4,12 +4,10 @@ This file contains implementation override of SearchResultProcessor which will a
* Confirms user access to object
* Confirms user access to object
"""
"""
from
django.core.urlresolvers
import
reverse
from
django.core.urlresolvers
import
reverse
from
django.utils.translation
import
ugettext
as
_
from
opaque_keys.edx.locations
import
SlashSeparatedCourseKey
from
opaque_keys.edx.locations
import
SlashSeparatedCourseKey
from
search.result_processor
import
SearchResultProcessor
from
search.result_processor
import
SearchResultProcessor
from
xmodule.modulestore.django
import
modulestore
from
xmodule.modulestore.django
import
modulestore
from
xmodule.modulestore.search
import
path_to_location
,
navigation_index
from
courseware.access
import
has_access
from
courseware.access
import
has_access
...
...
lms/tests.py
View file @
ba8fd1c2
...
@@ -10,7 +10,6 @@ from edxmako import add_lookup, LOOKUP
...
@@ -10,7 +10,6 @@ from edxmako import add_lookup, LOOKUP
from
lms
import
startup
from
lms
import
startup
from
xmodule.modulestore.tests.factories
import
CourseFactory
from
xmodule.modulestore.tests.factories
import
CourseFactory
from
xmodule.modulestore.tests.django_utils
import
ModuleStoreTestCase
from
xmodule.modulestore.tests.django_utils
import
ModuleStoreTestCase
from
util
import
keyword_substitution
class
LmsModuleTests
(
TestCase
):
class
LmsModuleTests
(
TestCase
):
...
...
lms/urls.py
View file @
ba8fd1c2
...
@@ -605,7 +605,6 @@ if settings.FEATURES.get('RUN_AS_ANALYTICS_SERVER_ENABLED'):
...
@@ -605,7 +605,6 @@ if settings.FEATURES.get('RUN_AS_ANALYTICS_SERVER_ENABLED'):
urlpatterns
+=
(
urlpatterns
+=
(
url
(
r'^edinsights_service/'
,
include
(
'edinsights.core.urls'
)),
url
(
r'^edinsights_service/'
,
include
(
'edinsights.core.urls'
)),
)
)
import
edinsights.core.registry
# FoldIt views
# FoldIt views
urlpatterns
+=
(
urlpatterns
+=
(
...
...
openedx/core/djangoapps/course_groups/tests/test_partition_scheme.py
View file @
ba8fd1c2
...
@@ -6,7 +6,6 @@ Test the partitions and partitions service
...
@@ -6,7 +6,6 @@ Test the partitions and partitions service
import
json
import
json
from
django.conf
import
settings
from
django.conf
import
settings
import
django.test
import
django.test
from
django.test.utils
import
override_settings
from
mock
import
patch
from
mock
import
patch
from
unittest
import
skipUnless
from
unittest
import
skipUnless
...
@@ -14,8 +13,8 @@ from courseware.masquerade import handle_ajax, setup_masquerade
...
@@ -14,8 +13,8 @@ from courseware.masquerade import handle_ajax, setup_masquerade
from
courseware.tests.test_masquerade
import
StaffMasqueradeTestCase
from
courseware.tests.test_masquerade
import
StaffMasqueradeTestCase
from
student.tests.factories
import
UserFactory
from
student.tests.factories
import
UserFactory
from
xmodule.partitions.partitions
import
Group
,
UserPartition
,
UserPartitionError
from
xmodule.partitions.partitions
import
Group
,
UserPartition
,
UserPartitionError
from
xmodule.modulestore.django
import
modulestore
,
clear_existing_modulestores
from
xmodule.modulestore.django
import
modulestore
from
xmodule.modulestore.tests.django_utils
import
ModuleStoreTestCase
,
mixed_store_config
,
TEST_DATA_MIXED_TOY_MODULESTORE
from
xmodule.modulestore.tests.django_utils
import
ModuleStoreTestCase
,
TEST_DATA_MIXED_TOY_MODULESTORE
from
opaque_keys.edx.locations
import
SlashSeparatedCourseKey
from
opaque_keys.edx.locations
import
SlashSeparatedCourseKey
from
openedx.core.djangoapps.user_api.partition_schemes
import
RandomUserPartitionScheme
from
openedx.core.djangoapps.user_api.partition_schemes
import
RandomUserPartitionScheme
...
...
openedx/core/djangoapps/course_groups/views.py
View file @
ba8fd1c2
...
@@ -7,7 +7,7 @@ from django.views.decorators.http import require_POST
...
@@ -7,7 +7,7 @@ from django.views.decorators.http import require_POST
from
django.contrib.auth.models
import
User
from
django.contrib.auth.models
import
User
from
django.core.paginator
import
Paginator
,
EmptyPage
from
django.core.paginator
import
Paginator
,
EmptyPage
from
django.core.urlresolvers
import
reverse
from
django.core.urlresolvers
import
reverse
from
django.http
import
Http404
,
HttpResponse
,
HttpResponse
BadRequest
from
django.http
import
Http404
,
HttpResponseBadRequest
from
django.views.decorators.http
import
require_http_methods
from
django.views.decorators.http
import
require_http_methods
from
util.json_request
import
expect_json
,
JsonResponse
from
util.json_request
import
expect_json
,
JsonResponse
from
django.contrib.auth.decorators
import
login_required
from
django.contrib.auth.decorators
import
login_required
...
...
openedx/core/djangoapps/user_api/forms.py
View file @
ba8fd1c2
# pylint: disable=unused-import, missing-docstring
# TODO: eventually move this implementation into the user_api
# TODO: eventually move this implementation into the user_api
from
student.forms
import
PasswordResetFormNoActive
from
student.forms
import
PasswordResetFormNoActive
openedx/core/djangoapps/user_api/management/tests/test_email_opt_in_list.py
View file @
ba8fd1c2
...
@@ -7,14 +7,11 @@ import csv
...
@@ -7,14 +7,11 @@ import csv
from
collections
import
defaultdict
from
collections
import
defaultdict
from
unittest
import
skipUnless
from
unittest
import
skipUnless
import
ddt
import
ddt
from
django.conf
import
settings
from
django.conf
import
settings
from
django.test.utils
import
override_settings
from
django.core.management.base
import
CommandError
from
django.core.management.base
import
CommandError
from
xmodule.modulestore.tests.django_utils
import
ModuleStoreTestCase
from
xmodule.modulestore.tests.django_utils
import
ModuleStoreTestCase
,
mixed_store_config
from
xmodule.modulestore.tests.factories
import
CourseFactory
from
xmodule.modulestore.tests.factories
import
CourseFactory
from
student.tests.factories
import
UserFactory
,
CourseEnrollmentFactory
from
student.tests.factories
import
UserFactory
,
CourseEnrollmentFactory
from
student.models
import
CourseEnrollment
from
student.models
import
CourseEnrollment
...
...
openedx/core/djangoapps/user_api/models.py
View file @
ba8fd1c2
from
django.contrib.auth.models
import
User
from
django.contrib.auth.models
import
User
from
django.core.validators
import
RegexValidator
from
django.core.validators
import
RegexValidator
from
django.db
import
models
from
django.db
import
models
from
django.db.models.signals
import
p
re_delete
,
p
ost_delete
,
pre_save
,
post_save
from
django.db.models.signals
import
post_delete
,
pre_save
,
post_save
from
django.dispatch
import
receiver
from
django.dispatch
import
receiver
from
model_utils.models
import
TimeStampedModel
from
model_utils.models
import
TimeStampedModel
...
...
openedx/core/djangoapps/user_api/tests/test_models.py
View file @
ba8fd1c2
import
json
"""
Test UserPreferenceModel and UserPreference events
"""
from
django.db
import
IntegrityError
from
django.db
import
IntegrityError
from
django.test
import
TestCase
from
django.test
import
TestCase
...
...
pavelib/paver_tests/test_paver_get_quality_reports.py
View file @
ba8fd1c2
import
os
"""
import
tempfile
Tests to ensure only the report files we want are returned as part of run_quality.
"""
import
unittest
import
unittest
from
mock
import
patch
,
Mock
from
mock
import
patch
from
ddt
import
ddt
,
file_data
import
pavelib.quality
import
pavelib.quality
import
paver.easy
from
paver.easy
import
BuildFailure
class
TestGetReportFiles
(
unittest
.
TestCase
):
class
TestGetReportFiles
(
unittest
.
TestCase
):
...
...
pavelib/tests.py
View file @
ba8fd1c2
...
@@ -3,7 +3,7 @@ Unit test tasks
...
@@ -3,7 +3,7 @@ Unit test tasks
"""
"""
import
os
import
os
import
sys
import
sys
from
paver.easy
import
sh
,
task
,
cmdopts
,
needs
,
call_task
,
no_help
from
paver.easy
import
sh
,
task
,
cmdopts
,
needs
,
call_task
from
pavelib.utils.test
import
suites
from
pavelib.utils.test
import
suites
from
pavelib.utils.envs
import
Env
from
pavelib.utils.envs
import
Env
from
optparse
import
make_option
from
optparse
import
make_option
...
...
pavelib/utils/test/suites/nose_suite.py
View file @
ba8fd1c2
...
@@ -2,7 +2,6 @@
...
@@ -2,7 +2,6 @@
Classes used for defining and running nose test suites
Classes used for defining and running nose test suites
"""
"""
import
os
import
os
from
paver.easy
import
call_task
from
pavelib.utils.test
import
utils
as
test_utils
from
pavelib.utils.test
import
utils
as
test_utils
from
pavelib.utils.test.suites.suite
import
TestSuite
from
pavelib.utils.test.suites.suite
import
TestSuite
from
pavelib.utils.envs
import
Env
from
pavelib.utils.envs
import
Env
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment