summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorTim Graham <timograham@gmail.com>2017-01-27 20:06:55 -0500
committerTim Graham <timograham@gmail.com>2017-01-28 10:14:11 -0500
commitaa52e8b77b9680581ff47a0e5e8046ba289bd59f (patch)
tree28011c1d8dff47c1bf97ce7cab522136cc32affb /tests
parentf706576adf16bd44fe10386a570cbb657b412066 (diff)
[1.11.x] Refs #27790 -- Reverted "Removed available_apps on TestCase subclasses."
This reverts commit 91023d79ec70df9289271e63a67675ee51e7dea8 as it increases memory usage for the test suite. Backport of 7d50d2bcb8a3cf3fea727174717ead7e6508e9e2 from master
Diffstat (limited to 'tests')
-rw-r--r--tests/multiple_database/tests.py6
-rw-r--r--tests/swappable_models/tests.py7
2 files changed, 13 insertions, 0 deletions
diff --git a/tests/multiple_database/tests.py b/tests/multiple_database/tests.py
index 0ea3b6667e..25483d5bdf 100644
--- a/tests/multiple_database/tests.py
+++ b/tests/multiple_database/tests.py
@@ -1794,6 +1794,12 @@ class SyncOnlyDefaultDatabaseRouter(object):
class MigrateTestCase(TestCase):
+ # Limit memory usage when calling 'migrate'.
+ available_apps = [
+ 'multiple_database',
+ 'django.contrib.auth',
+ 'django.contrib.contenttypes'
+ ]
multi_db = True
def test_migrate_to_other_database(self):
diff --git a/tests/swappable_models/tests.py b/tests/swappable_models/tests.py
index 548c7b3286..06aa373d9a 100644
--- a/tests/swappable_models/tests.py
+++ b/tests/swappable_models/tests.py
@@ -11,6 +11,13 @@ from django.utils.six import StringIO
class SwappableModelTests(TestCase):
+ # Limit memory usage when calling 'migrate'.
+ available_apps = [
+ 'swappable_models',
+ 'django.contrib.auth',
+ 'django.contrib.contenttypes',
+ ]
+
@override_settings(TEST_ARTICLE_MODEL='swappable_models.AlternateArticle')
def test_generated_data(self):
"Permissions and content types are not created for a swapped model"