incr-205 ran modernize on common/djangoapps/course_modes (#20465)

This commit is contained in:
Kyle Mulka
2019-05-08 13:35:40 -04:00
committed by Michael Youngstrom
parent 68c1c19478
commit b2e6ed0488
4 changed files with 7 additions and 7 deletions

View File

@@ -3,9 +3,9 @@ Tests for the course modes API.
"""
from __future__ import absolute_import, unicode_literals
from itertools import product
import json
import unittest
from itertools import product
import ddt
from django.conf import settings
@@ -20,7 +20,7 @@ from course_modes.models import CourseMode
from course_modes.tests.factories import CourseModeFactory
from openedx.core.djangoapps.content.course_overviews.tests.factories import CourseOverviewFactory
from openedx.core.djangoapps.oauth_dispatch.toggles import ENFORCE_JWT_SCOPES
from openedx.core.djangoapps.user_authn.tests.utils import AuthAndScopesTestMixin, AuthType, JWT_AUTH_TYPES
from openedx.core.djangoapps.user_authn.tests.utils import JWT_AUTH_TYPES, AuthAndScopesTestMixin, AuthType
from student.tests.factories import UserFactory

View File

@@ -2,12 +2,12 @@
URL definitions for the course_modes v1 API.
"""
from __future__ import absolute_import
from django.conf import settings
from django.conf.urls import url
from course_modes.api.v1 import views
app_name = 'v1'
urlpatterns = [

View File

@@ -3,6 +3,7 @@ Defines the "ReSTful" API for course modes.
"""
from __future__ import absolute_import
import logging
from django.shortcuts import get_object_or_404
@@ -14,11 +15,10 @@ from rest_framework import status
from rest_framework.generics import ListCreateAPIView, RetrieveUpdateDestroyAPIView
from rest_framework.response import Response
from openedx.core.lib.api.authentication import OAuth2AuthenticationAllowInactiveUser
from openedx.core.lib.api.parsers import MergePatchParser
from course_modes.api.serializers import CourseModeSerializer
from course_modes.models import CourseMode
from openedx.core.lib.api.authentication import OAuth2AuthenticationAllowInactiveUser
from openedx.core.lib.api.parsers import MergePatchParser
log = logging.getLogger(__name__)

View File

@@ -6,12 +6,12 @@ from __future__ import absolute_import, unicode_literals
from datetime import datetime, timedelta
import ddt
from django.conf import settings
from mock import patch
from pytz import UTC
from course_modes.models import CourseMode
from course_modes.signals import _listen_for_course_publish
from django.conf import settings
from xmodule.modulestore import ModuleStoreEnum
from xmodule.modulestore.tests.django_utils import ModuleStoreTestCase
from xmodule.modulestore.tests.factories import CourseFactory, ItemFactory