Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
def test_init(cache):
default_settings = dc.DEFAULT_SETTINGS.copy()
del default_settings['size_limit']
for key, value in default_settings.items():
assert getattr(cache, key) == value
assert cache.size_limit == 2 ** 27
cache.check()
for key, value in dc.DEFAULT_SETTINGS.items():
setattr(cache, key, value)
cache.check()