mirror of
https://github.com/borgbackup/borg.git
synced 2025-02-25 15:33:39 +00:00
fix RepositoryTestCaseBase.reopen method
"if self.repository" did not work as expected: - Repository has a __len__ method, so the boolean evaluation was calling that. - self.repository is also not set to None anywhere.
This commit is contained in:
parent
27f2dffdf8
commit
3d82be0b58
1 changed files with 1 additions and 2 deletions
|
@ -65,8 +65,7 @@ def tearDown(self):
|
||||||
shutil.rmtree(self.tmppath)
|
shutil.rmtree(self.tmppath)
|
||||||
|
|
||||||
def reopen(self, exclusive=UNSPECIFIED):
|
def reopen(self, exclusive=UNSPECIFIED):
|
||||||
if self.repository:
|
self.repository.close()
|
||||||
self.repository.close()
|
|
||||||
self.repository = self.open(exclusive=exclusive)
|
self.repository = self.open(exclusive=exclusive)
|
||||||
|
|
||||||
def add_keys(self):
|
def add_keys(self):
|
||||||
|
|
Loading…
Reference in a new issue