Merge pull request #22576 from edx/BOM-1109

Updated the django-waffle to support django 2.2
This commit is contained in:
Aarif
2020-01-08 18:47:12 +05:00
committed by GitHub
9 changed files with 23 additions and 23 deletions

View File

@@ -398,13 +398,13 @@ class TestCourseIndexArchived(CourseTestCase):
@ddt.data(
# Staff user has course staff access
(True, 'staff', None, 3, 18),
(False, 'staff', None, 3, 18),
(True, 'staff', None, 3, 19),
(False, 'staff', None, 3, 19),
# Base user has global staff access
(True, 'user', ORG, 3, 18),
(False, 'user', ORG, 3, 18),
(True, 'user', None, 3, 18),
(False, 'user', None, 3, 18),
(True, 'user', ORG, 3, 19),
(False, 'user', ORG, 3, 19),
(True, 'user', None, 3, 19),
(False, 'user', None, 3, 19),
)
@ddt.unpack
def test_separate_archived_courses(self, separate_archived_courses, username, org, mongo_queries, sql_queries):

View File

@@ -270,7 +270,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(22):
with self.assertNumQueries(21):
resp = self.get_response(
AuthType.jwt,
requesting_user=student_no_cert,
@@ -280,7 +280,7 @@ class CertificatesListRestApiTest(AuthAndScopesTestMixin, SharedModuleStoreTestC
self.assertEqual(len(resp.data), 0)
# Test student with 1 certificate
with self.assertNumQueries(17):
with self.assertNumQueries(14):
resp = self.get_response(
AuthType.jwt,
requesting_user=self.student,
@@ -320,7 +320,7 @@ class CertificatesListRestApiTest(AuthAndScopesTestMixin, SharedModuleStoreTestC
download_url='www.google.com',
grade="0.88",
)
with self.assertNumQueries(17):
with self.assertNumQueries(14):
resp = self.get_response(
AuthType.jwt,
requesting_user=student_2_certs,

View File

@@ -475,7 +475,7 @@ class CourseListSearchViewTest(CourseApiTestViewMixin, ModuleStoreTestCase, Sear
self.setup_user(self.audit_user)
# These query counts were found empirically
query_counts = [63, 50, 50, 50, 50, 50, 50, 50, 50, 50, 20]
query_counts = [63, 45, 45, 45, 45, 45, 45, 45, 45, 45, 15]
ordered_course_ids = sorted([str(cid) for cid in (course_ids + [c.id for c in self.courses])])
self.clear_caches()

View File

@@ -269,7 +269,7 @@ class BookmarksListViewTests(BookmarksViewsTestsBase):
self.assertEqual(response.data['developer_message'], u'Parameter usage_id not provided.')
# Send empty data dictionary.
with self.assertNumQueries(9): # No queries for bookmark table.
with self.assertNumQueries(8): # No queries for bookmark table.
response = self.send_post(
client=self.client,
url=reverse('bookmarks'),

View File

@@ -499,7 +499,7 @@ class TestAccountsAPI(CacheIsolationTestCase, UserAPITestCase):
# Now make sure that the user can get the same information, even if not active
self.user.is_active = False
self.user.save()
verify_get_own_information(15)
verify_get_own_information(13)
def test_get_account_empty_string(self):
"""

View File

@@ -62,7 +62,7 @@ django-splash
django-statici18n
django-storages
django-user-tasks
django-waffle==0.12.0
django-waffle==0.18.0
django-webpack-loader # Used to wire webpack bundles into the django asset pipeline
djangorestframework==3.9.4
djangorestframework-jwt

View File

@@ -56,7 +56,7 @@ django-babel-underscore==0.5.2
django-babel==0.6.2 # via django-babel-underscore
git+https://github.com/edx/django-celery.git@756cb57aad765cb2b0d37372c1855b8f5f37e6b0#egg=django-celery==3.2.1+edx.2
django-classy-tags==0.9.0 # via django-sekizai
django-config-models==1.0.3
django-config-models==1.0.4
django-cors-headers==2.5.3
django-countries==5.5
django-crum==0.7.5
@@ -83,7 +83,7 @@ django-splash==0.2.5
django-statici18n==1.8.3
django-storages==1.8
django-user-tasks==0.3.0
django-waffle==0.12.0
django-waffle==0.18.0
django-webpack-loader==0.6.0
django==1.11.27
djangorestframework-jwt==1.11.0
@@ -163,7 +163,7 @@ mpmath==1.1.0 # via sympy
mysqlclient==1.4.6
newrelic==5.4.1.134
nltk==3.4.5
nodeenv==1.3.3
nodeenv==1.3.4
numpy==1.18.1 # via scipy
git+https://github.com/joestump/python-oauth2.git@b94f69b1ad195513547924e380d9265133e995fa#egg=oauth2
oauthlib==2.1.0

View File

@@ -68,7 +68,7 @@ django-babel-underscore==0.5.2
django-babel==0.6.2
git+https://github.com/edx/django-celery.git@756cb57aad765cb2b0d37372c1855b8f5f37e6b0#egg=django-celery==3.2.1+edx.2
django-classy-tags==0.9.0
django-config-models==1.0.3
django-config-models==1.0.4
django-cors-headers==2.5.3
django-countries==5.5
django-crum==0.7.5
@@ -96,7 +96,7 @@ django-splash==0.2.5
django-statici18n==1.8.3
django-storages==1.8
django-user-tasks==0.3.0
django-waffle==0.12.0
django-waffle==0.18.0
django-webpack-loader==0.6.0
django==1.11.27
djangorestframework-jwt==1.11.0
@@ -202,7 +202,7 @@ mpmath==1.1.0
mysqlclient==1.4.6
newrelic==5.4.1.134
nltk==3.4.5
nodeenv==1.3.3
nodeenv==1.3.4
numpy==1.18.1
git+https://github.com/joestump/python-oauth2.git@b94f69b1ad195513547924e380d9265133e995fa#egg=oauth2
oauthlib==2.1.0
@@ -244,7 +244,7 @@ pymongo==3.9.0
pynliner==0.8.0
pyparsing==2.2.0
pyquery==1.4.1
pyrsistent==0.15.6 # via jsonschema
pyrsistent==0.15.7 # via jsonschema
pysrt==1.1.1
pytest-attrib==0.1.3
pytest-cov==2.8.1

View File

@@ -67,7 +67,7 @@ django-babel-underscore==0.5.2
django-babel==0.6.2
git+https://github.com/edx/django-celery.git@756cb57aad765cb2b0d37372c1855b8f5f37e6b0#egg=django-celery==3.2.1+edx.2
django-classy-tags==0.9.0
django-config-models==1.0.3
django-config-models==1.0.4
django-cors-headers==2.5.3
django-countries==5.5
django-crum==0.7.5
@@ -94,7 +94,7 @@ django-splash==0.2.5
django-statici18n==1.8.3
django-storages==1.8
django-user-tasks==0.3.0
django-waffle==0.12.0
django-waffle==0.18.0
django-webpack-loader==0.6.0
djangorestframework-jwt==1.11.0
git+https://github.com/edx/django-rest-framework-oauth.git@0a43e8525f1e3048efe4bc70c03de308a277197c#egg=djangorestframework-oauth==1.1.1
@@ -194,7 +194,7 @@ mpmath==1.1.0
mysqlclient==1.4.6
newrelic==5.4.1.134
nltk==3.4.5
nodeenv==1.3.3
nodeenv==1.3.4
numpy==1.18.1
git+https://github.com/joestump/python-oauth2.git@b94f69b1ad195513547924e380d9265133e995fa#egg=oauth2
oauthlib==2.1.0