Merge pull request #34528 from openedx/feanil/remove_django_splash
feat!: Remove the django-splash app.
This commit is contained in:
@@ -309,7 +309,7 @@ class CertificatesListRestApiTest(AuthAndScopesTestMixin, SharedModuleStoreTestC
|
||||
def test_query_counts(self):
|
||||
# Test student with no certificates
|
||||
student_no_cert = UserFactory.create(password=self.user_password)
|
||||
with self.assertNumQueries(21, table_ignorelist=WAFFLE_TABLES):
|
||||
with self.assertNumQueries(20, table_ignorelist=WAFFLE_TABLES):
|
||||
resp = self.get_response(
|
||||
AuthType.jwt,
|
||||
requesting_user=self.global_staff,
|
||||
|
||||
@@ -434,7 +434,7 @@ class CourseListSearchViewTest(CourseApiTestViewMixin, ModuleStoreTestCase, Sear
|
||||
self.setup_user(self.audit_user)
|
||||
|
||||
# These query counts were found empirically
|
||||
query_counts = [53, 46, 46, 46, 46, 46, 46, 46, 46, 46, 16]
|
||||
query_counts = [52, 46, 46, 46, 46, 46, 46, 46, 46, 46, 16]
|
||||
ordered_course_ids = sorted([str(cid) for cid in (course_ids + [c.id for c in self.courses])])
|
||||
|
||||
self.clear_caches()
|
||||
|
||||
@@ -365,7 +365,7 @@ class IndexQueryTestCase(ModuleStoreTestCase):
|
||||
self.client.login(username=self.user.username, password=self.user_password)
|
||||
CourseEnrollment.enroll(self.user, course.id)
|
||||
|
||||
with self.assertNumQueries(178, table_ignorelist=QUERY_COUNT_TABLE_IGNORELIST):
|
||||
with self.assertNumQueries(177, table_ignorelist=QUERY_COUNT_TABLE_IGNORELIST):
|
||||
with check_mongo_calls(3):
|
||||
url = reverse(
|
||||
'courseware_section',
|
||||
@@ -1496,8 +1496,8 @@ class ProgressPageTests(ProgressPageBaseTests):
|
||||
self.assertContains(resp, "earned a certificate for this course.")
|
||||
|
||||
@ddt.data(
|
||||
(True, 54),
|
||||
(False, 54),
|
||||
(True, 53),
|
||||
(False, 53),
|
||||
)
|
||||
@ddt.unpack
|
||||
def test_progress_queries_paced_courses(self, self_paced, query_count):
|
||||
@@ -1512,7 +1512,7 @@ class ProgressPageTests(ProgressPageBaseTests):
|
||||
ContentTypeGatingConfig.objects.create(enabled=True, enabled_as_of=datetime(2018, 1, 1))
|
||||
self.setup_course()
|
||||
with self.assertNumQueries(
|
||||
54, table_ignorelist=QUERY_COUNT_TABLE_IGNORELIST
|
||||
53, table_ignorelist=QUERY_COUNT_TABLE_IGNORELIST
|
||||
), check_mongo_calls(2):
|
||||
self._get_progress_page()
|
||||
|
||||
|
||||
@@ -410,7 +410,7 @@ class ViewsQueryCountTestCase(
|
||||
return inner
|
||||
|
||||
@ddt.data(
|
||||
(ModuleStoreEnum.Type.split, 3, 8, 43),
|
||||
(ModuleStoreEnum.Type.split, 3, 8, 42),
|
||||
)
|
||||
@ddt.unpack
|
||||
@count_queries
|
||||
@@ -418,7 +418,7 @@ class ViewsQueryCountTestCase(
|
||||
self.create_thread_helper(mock_request)
|
||||
|
||||
@ddt.data(
|
||||
(ModuleStoreEnum.Type.split, 3, 6, 42),
|
||||
(ModuleStoreEnum.Type.split, 3, 6, 41),
|
||||
)
|
||||
@ddt.unpack
|
||||
@count_queries
|
||||
|
||||
@@ -2286,8 +2286,6 @@ MIDDLEWARE = [
|
||||
'openedx.core.djangoapps.cors_csrf.middleware.CorsCSRFMiddleware',
|
||||
'openedx.core.djangoapps.cors_csrf.middleware.CsrfCrossDomainCookieMiddleware',
|
||||
|
||||
'splash.middleware.SplashMiddleware',
|
||||
|
||||
'openedx.core.djangoapps.geoinfo.middleware.CountryMiddleware',
|
||||
'openedx.core.djangoapps.embargo.middleware.EmbargoMiddleware',
|
||||
|
||||
@@ -3162,9 +3160,6 @@ INSTALLED_APPS = [
|
||||
# Notes
|
||||
'lms.djangoapps.edxnotes',
|
||||
|
||||
# Splash screen
|
||||
'splash',
|
||||
|
||||
# User API
|
||||
'rest_framework',
|
||||
|
||||
|
||||
@@ -232,7 +232,7 @@ class TestOwnUsernameAPI(FilteredQueryCountMixin, CacheIsolationTestCase, UserAP
|
||||
Test that a client (logged in) can get her own username.
|
||||
"""
|
||||
self.client.login(username=self.user.username, password=TEST_PASSWORD)
|
||||
self._verify_get_own_username(19)
|
||||
self._verify_get_own_username(18)
|
||||
|
||||
def test_get_username_inactive(self):
|
||||
"""
|
||||
@@ -242,7 +242,7 @@ class TestOwnUsernameAPI(FilteredQueryCountMixin, CacheIsolationTestCase, UserAP
|
||||
self.client.login(username=self.user.username, password=TEST_PASSWORD)
|
||||
self.user.is_active = False
|
||||
self.user.save()
|
||||
self._verify_get_own_username(19)
|
||||
self._verify_get_own_username(18)
|
||||
|
||||
def test_get_username_not_logged_in(self):
|
||||
"""
|
||||
@@ -251,7 +251,7 @@ class TestOwnUsernameAPI(FilteredQueryCountMixin, CacheIsolationTestCase, UserAP
|
||||
"""
|
||||
|
||||
# verify that the endpoint is inaccessible when not logged in
|
||||
self._verify_get_own_username(12, expected_status=401)
|
||||
self._verify_get_own_username(11, expected_status=401)
|
||||
|
||||
|
||||
@skip_unless_lms
|
||||
@@ -358,7 +358,7 @@ class TestAccountsAPI(FilteredQueryCountMixin, CacheIsolationTestCase, UserAPITe
|
||||
"""
|
||||
|
||||
ENABLED_CACHES = ['default']
|
||||
TOTAL_QUERY_COUNT = 27
|
||||
TOTAL_QUERY_COUNT = 26
|
||||
FULL_RESPONSE_FIELD_COUNT = 29
|
||||
|
||||
def setUp(self):
|
||||
@@ -811,7 +811,7 @@ class TestAccountsAPI(FilteredQueryCountMixin, CacheIsolationTestCase, UserAPITe
|
||||
assert data['time_zone'] is None
|
||||
|
||||
self.client.login(username=self.user.username, password=TEST_PASSWORD)
|
||||
verify_get_own_information(self._get_num_queries(25))
|
||||
verify_get_own_information(self._get_num_queries(24))
|
||||
|
||||
# Now make sure that the user can get the same information, even if not active
|
||||
self.user.is_active = False
|
||||
@@ -831,7 +831,7 @@ class TestAccountsAPI(FilteredQueryCountMixin, CacheIsolationTestCase, UserAPITe
|
||||
legacy_profile.save()
|
||||
|
||||
self.client.login(username=self.user.username, password=TEST_PASSWORD)
|
||||
with self.assertNumQueries(self._get_num_queries(25), table_ignorelist=WAFFLE_TABLES):
|
||||
with self.assertNumQueries(self._get_num_queries(24), table_ignorelist=WAFFLE_TABLES):
|
||||
response = self.send_get(self.client)
|
||||
for empty_field in ("level_of_education", "gender", "country", "state", "bio",):
|
||||
assert response.data[empty_field] is None
|
||||
|
||||
@@ -49,7 +49,7 @@ class TestCourseUpdatesPage(BaseCourseUpdatesTestCase):
|
||||
|
||||
# Fetch the view and verify that the query counts haven't changed
|
||||
# TODO: decrease query count as part of REVO-28
|
||||
with self.assertNumQueries(53, table_ignorelist=QUERY_COUNT_TABLE_IGNORELIST):
|
||||
with self.assertNumQueries(52, table_ignorelist=QUERY_COUNT_TABLE_IGNORELIST):
|
||||
with check_mongo_calls(3):
|
||||
url = course_updates_url(self.course)
|
||||
self.client.get(url)
|
||||
|
||||
@@ -198,7 +198,6 @@ django==4.2.10
|
||||
# django-oauth-toolkit
|
||||
# django-sekizai
|
||||
# django-ses
|
||||
# django-splash
|
||||
# django-statici18n
|
||||
# django-storages
|
||||
# django-user-tasks
|
||||
@@ -350,8 +349,6 @@ django-simple-history==3.4.0
|
||||
# edx-organizations
|
||||
# edx-proctoring
|
||||
# ora2
|
||||
django-splash==1.3.0
|
||||
# via -r requirements/edx/kernel.in
|
||||
django-statici18n==2.4.0
|
||||
# via
|
||||
# -r requirements/edx/kernel.in
|
||||
|
||||
@@ -364,7 +364,6 @@ django==4.2.10
|
||||
# django-oauth-toolkit
|
||||
# django-sekizai
|
||||
# django-ses
|
||||
# django-splash
|
||||
# django-statici18n
|
||||
# django-storages
|
||||
# django-stubs
|
||||
@@ -568,10 +567,6 @@ django-simple-history==3.4.0
|
||||
# edx-organizations
|
||||
# edx-proctoring
|
||||
# ora2
|
||||
django-splash==1.3.0
|
||||
# via
|
||||
# -r requirements/edx/doc.txt
|
||||
# -r requirements/edx/testing.txt
|
||||
django-statici18n==2.4.0
|
||||
# via
|
||||
# -r requirements/edx/doc.txt
|
||||
|
||||
@@ -248,7 +248,6 @@ django==4.2.10
|
||||
# django-oauth-toolkit
|
||||
# django-sekizai
|
||||
# django-ses
|
||||
# django-splash
|
||||
# django-statici18n
|
||||
# django-storages
|
||||
# django-user-tasks
|
||||
@@ -416,8 +415,6 @@ django-simple-history==3.4.0
|
||||
# edx-organizations
|
||||
# edx-proctoring
|
||||
# ora2
|
||||
django-splash==1.3.0
|
||||
# via -r requirements/edx/base.txt
|
||||
django-statici18n==2.4.0
|
||||
# via
|
||||
# -r requirements/edx/base.txt
|
||||
|
||||
@@ -51,7 +51,6 @@ django-pipeline
|
||||
django-ratelimit
|
||||
django-sekizai
|
||||
django-simple-history
|
||||
django-splash
|
||||
django-statici18n
|
||||
django-storages
|
||||
django-user-tasks
|
||||
|
||||
@@ -277,7 +277,6 @@ django==4.2.10
|
||||
# django-oauth-toolkit
|
||||
# django-sekizai
|
||||
# django-ses
|
||||
# django-splash
|
||||
# django-statici18n
|
||||
# django-storages
|
||||
# django-user-tasks
|
||||
@@ -445,8 +444,6 @@ django-simple-history==3.4.0
|
||||
# edx-organizations
|
||||
# edx-proctoring
|
||||
# ora2
|
||||
django-splash==1.3.0
|
||||
# via -r requirements/edx/base.txt
|
||||
django-statici18n==2.4.0
|
||||
# via
|
||||
# -r requirements/edx/base.txt
|
||||
|
||||
Reference in New Issue
Block a user