summaryrefslogtreecommitdiff
path: root/tests/cache
diff options
context:
space:
mode:
authorMariusz Felisiak <felisiak.mariusz@gmail.com>2022-02-08 12:27:04 +0100
committerMariusz Felisiak <felisiak.mariusz@gmail.com>2022-02-08 19:25:02 +0100
commit3278c31fa59b41d03aea167f4cf85f4ddf7f848d (patch)
tree0c80b4868391296335580242c8e65052a4f62a6b /tests/cache
parent6a682b38e75d4c975b4c4493565a59f1bc14397c (diff)
[4.0.x] Refs #33476 -- Refactored code to strictly match 88 characters line length.
Backport of 7119f40c9881666b6f9b5cf7df09ee1d21cc8344 from main.
Diffstat (limited to 'tests/cache')
-rw-r--r--tests/cache/tests.py15
1 files changed, 8 insertions, 7 deletions
diff --git a/tests/cache/tests.py b/tests/cache/tests.py
index 51ca4c37f9..7764b92597 100644
--- a/tests/cache/tests.py
+++ b/tests/cache/tests.py
@@ -1761,9 +1761,9 @@ class FileBasedCacheTests(BaseCacheTests, TestCase):
def setUp(self):
super().setUp()
self.dirname = self.mkdtemp()
- # Caches location cannot be modified through override_settings / modify_settings,
- # hence settings are manipulated directly here and the setting_changed signal
- # is triggered manually.
+ # Caches location cannot be modified through override_settings /
+ # modify_settings, hence settings are manipulated directly here and the
+ # setting_changed signal is triggered manually.
for cache_params in settings.CACHES.values():
cache_params["LOCATION"] = self.dirname
setting_changed.send(self.__class__, setting="CACHES", enter=False)
@@ -2160,7 +2160,8 @@ class CacheUtils(SimpleTestCase):
def test_patch_cache_control(self):
tests = (
- # Initial Cache-Control, kwargs to patch_cache_control, expected Cache-Control parts
+ # Initial Cache-Control, kwargs to patch_cache_control, expected
+ # Cache-Control parts.
(None, {"private": True}, {"private"}),
("", {"private": True}, {"private"}),
# no-cache.
@@ -2541,9 +2542,9 @@ class CacheMiddlewareTest(SimpleTestCase):
def test_constructor(self):
"""
- Ensure the constructor is correctly distinguishing between usage of CacheMiddleware as
- Middleware vs. usage of CacheMiddleware as view decorator and setting attributes
- appropriately.
+ The constructor is correctly distinguishing between usage of
+ CacheMiddleware as Middleware vs. usage of CacheMiddleware as view
+ decorator and setting attributes appropriately.
"""
# If only one argument is passed in construction, it's being used as
# middleware.