summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorTim Graham <timograham@gmail.com>2017-09-02 19:59:45 -0400
committerTim Graham <timograham@gmail.com>2017-09-22 12:51:17 -0400
commite47b56d791eb6c81c6d83529b7a068959ea1c1ec (patch)
tree9e3dfc877277ecf34351d415e79fa9269e8f26b2 /tests
parent87d2240e6cc594a3bf28dfdb2ec023c54fb76ff7 (diff)
Refs #20892 -- Removed support for passing pylibmc behavior settings as top-level attributes of CACHES['OPTIONS'].
Per deprecation timeline.
Diffstat (limited to 'tests')
-rw-r--r--tests/cache/tests.py18
1 files changed, 0 insertions, 18 deletions
diff --git a/tests/cache/tests.py b/tests/cache/tests.py
index e093dc842d..d3c9513303 100644
--- a/tests/cache/tests.py
+++ b/tests/cache/tests.py
@@ -1308,24 +1308,6 @@ class PyLibMCCacheTests(BaseMemcachedTests, TestCase):
self.assertTrue(cache._cache.binary)
self.assertEqual(cache._cache.behaviors['tcp_nodelay'], int(True))
- @override_settings(CACHES=caches_setting_for_tests(
- base=PyLibMCCache_params,
- exclude=memcached_excluded_caches,
- OPTIONS={'tcp_nodelay': True},
- ))
- def test_pylibmc_legacy_options(self):
- deprecation_message = (
- "Specifying pylibmc cache behaviors as a top-level property "
- "within `OPTIONS` is deprecated. Move `tcp_nodelay` into a dict named "
- "`behaviors` inside `OPTIONS` instead."
- )
- with warnings.catch_warnings(record=True) as warns:
- warnings.simplefilter("always")
- self.assertEqual(cache._cache.behaviors['tcp_nodelay'], int(True))
- self.assertEqual(len(warns), 1)
- self.assertIsInstance(warns[0].message, RemovedInDjango21Warning)
- self.assertEqual(str(warns[0].message), deprecation_message)
-
@override_settings(CACHES=caches_setting_for_tests(
BACKEND='django.core.cache.backends.filebased.FileBasedCache',