def test_working_dir_does_not_exist(self): working_dir = os.path.join(self.tempdir, 'foo') cache = assumerole.JSONFileCache(working_dir) cache['foo'] = {'bar': 'baz'} self.assertEqual(cache['foo'], {'bar': 'baz'})
def setUp(self): self.tempdir = tempfile.mkdtemp() self.cache = assumerole.JSONFileCache(self.tempdir)