Пример #1
0
 def __setup_file_cache(self, conf):
     file_cache_dir = conf.get('file_cache_dir', None)
     self.file_cache = Cache(file_cache_dir) if file_cache_dir else None
Пример #2
0
 def setUp(self):
     self.temp_dir = mkdtemp()
     self.temp_file = NamedTemporaryFile(delete=False)
     self.temp_file.write(b"Hello World!")
     self.temp_file.close()
     self.cache = Cache(self.temp_dir)