From 366a7e9412a97034d0e473ee67f324cbcb97377c Mon Sep 17 00:00:00 2001 From: Yusuf Musleh Date: Fri, 30 Aug 2024 09:20:01 +0300 Subject: [PATCH] refactor: Move Collections views/tests --- .../core/djangoapps/content_libraries/collections/__init__.py | 0 .../content_libraries/collections/rest_api/__init__.py | 0 .../content_libraries/collections/rest_api/v1/__init__.py | 0 .../collections/rest_api/v1/tests/__init__.py | 0 .../tests/test_views.py => tests/test_views_collections.py} | 0 openedx/core/djangoapps/content_libraries/urls.py | 4 ++-- .../rest_api/v1/views.py => views_collections.py} | 0 7 files changed, 2 insertions(+), 2 deletions(-) delete mode 100644 openedx/core/djangoapps/content_libraries/collections/__init__.py delete mode 100644 openedx/core/djangoapps/content_libraries/collections/rest_api/__init__.py delete mode 100644 openedx/core/djangoapps/content_libraries/collections/rest_api/v1/__init__.py delete mode 100644 openedx/core/djangoapps/content_libraries/collections/rest_api/v1/tests/__init__.py rename openedx/core/djangoapps/content_libraries/{collections/rest_api/v1/tests/test_views.py => tests/test_views_collections.py} (100%) rename openedx/core/djangoapps/content_libraries/{collections/rest_api/v1/views.py => views_collections.py} (100%) diff --git a/openedx/core/djangoapps/content_libraries/collections/__init__.py b/openedx/core/djangoapps/content_libraries/collections/__init__.py deleted file mode 100644 index e69de29bb2d1..000000000000 diff --git a/openedx/core/djangoapps/content_libraries/collections/rest_api/__init__.py b/openedx/core/djangoapps/content_libraries/collections/rest_api/__init__.py deleted file mode 100644 index e69de29bb2d1..000000000000 diff --git a/openedx/core/djangoapps/content_libraries/collections/rest_api/v1/__init__.py b/openedx/core/djangoapps/content_libraries/collections/rest_api/v1/__init__.py deleted file mode 100644 index e69de29bb2d1..000000000000 diff --git a/openedx/core/djangoapps/content_libraries/collections/rest_api/v1/tests/__init__.py b/openedx/core/djangoapps/content_libraries/collections/rest_api/v1/tests/__init__.py deleted file mode 100644 index e69de29bb2d1..000000000000 diff --git a/openedx/core/djangoapps/content_libraries/collections/rest_api/v1/tests/test_views.py b/openedx/core/djangoapps/content_libraries/tests/test_views_collections.py similarity index 100% rename from openedx/core/djangoapps/content_libraries/collections/rest_api/v1/tests/test_views.py rename to openedx/core/djangoapps/content_libraries/tests/test_views_collections.py diff --git a/openedx/core/djangoapps/content_libraries/urls.py b/openedx/core/djangoapps/content_libraries/urls.py index a0c5a9f8cd61..9455f0de5e61 100644 --- a/openedx/core/djangoapps/content_libraries/urls.py +++ b/openedx/core/djangoapps/content_libraries/urls.py @@ -7,7 +7,7 @@ from rest_framework import routers from . import views -from .collections.rest_api.v1 import views as collection_views +from . import views_collections # Django application name. @@ -21,7 +21,7 @@ library_collections_router = routers.DefaultRouter() library_collections_router.register( - r'collections', collection_views.LibraryCollectionsView, basename="library-collections" + r'collections', views_collections.LibraryCollectionsView, basename="library-collections" ) # These URLs are only used in Studio. The LMS already provides all the diff --git a/openedx/core/djangoapps/content_libraries/collections/rest_api/v1/views.py b/openedx/core/djangoapps/content_libraries/views_collections.py similarity index 100% rename from openedx/core/djangoapps/content_libraries/collections/rest_api/v1/views.py rename to openedx/core/djangoapps/content_libraries/views_collections.py