def test_cache(self): cache = os.path.join(self.tmp, 'cache') r = Cache(cache) r.retrieve(self.url) assert os.path.exists(os.path.join(cache, 'abc.txt'))