diff options
Diffstat (limited to 'tests/cache')
| -rw-r--r-- | tests/cache/closeable_cache.py | 2 | ||||
| -rw-r--r-- | tests/cache/liberal_backend.py | 2 | ||||
| -rw-r--r-- | tests/cache/tests.py | 10 |
3 files changed, 7 insertions, 7 deletions
diff --git a/tests/cache/closeable_cache.py b/tests/cache/closeable_cache.py index 1ac868dde9..a9e99a62cd 100644 --- a/tests/cache/closeable_cache.py +++ b/tests/cache/closeable_cache.py @@ -1,7 +1,7 @@ from django.core.cache.backends.locmem import LocMemCache -class CloseHookMixin(object): +class CloseHookMixin: closed = False def close(self, **kwargs): diff --git a/tests/cache/liberal_backend.py b/tests/cache/liberal_backend.py index 339066b0ff..93dc39a0d7 100644 --- a/tests/cache/liberal_backend.py +++ b/tests/cache/liberal_backend.py @@ -1,7 +1,7 @@ from django.core.cache.backends.locmem import LocMemCache -class LiberalKeyValidationMixin(object): +class LiberalKeyValidationMixin: def validate_key(self, key): pass diff --git a/tests/cache/tests.py b/tests/cache/tests.py index dd886cd11b..bfceff9b02 100644 --- a/tests/cache/tests.py +++ b/tests/cache/tests.py @@ -56,12 +56,12 @@ class C: return 24 -class Unpicklable(object): +class Unpicklable: def __getstate__(self): raise pickle.PickleError() -class UnpicklableType(object): +class UnpicklableType: # Unpicklable using the default pickling protocol on Python 2. __slots__ = 'a', @@ -251,7 +251,7 @@ def caches_setting_for_tests(base=None, exclude=None, **params): return setting -class BaseCacheTests(object): +class BaseCacheTests: # A common set of tests to apply to all cache backends def setUp(self): @@ -1010,7 +1010,7 @@ class DBCacheWithTimeZoneTests(DBCacheTests): pass -class DBCacheRouter(object): +class DBCacheRouter: """A router that puts the cache table on the 'other' database.""" def db_for_read(self, model, **hints): @@ -1061,7 +1061,7 @@ class CreateCacheTableForDBCacheTests(TestCase): verbosity=0, interactive=False) -class PicklingSideEffect(object): +class PicklingSideEffect: def __init__(self, cache): self.cache = cache |
