mirror of
https://github.com/outbackdingo/patroni.git
synced 2026-08-25 14:53:37 +00:00
Keep only latest failed data directory (#2471)
Use constant postfix when moving data directory due to failure so it only keeps data from the latest failure.
This commit is contained in:
@@ -438,6 +438,8 @@ class TestPostgresql(BaseTestPostgresql):
|
||||
self.assertTrue(self.p.stop())
|
||||
|
||||
@patch('os.rename', Mock())
|
||||
@patch('os.path.exists', Mock(return_value=True))
|
||||
@patch('shutil.rmtree', Mock())
|
||||
@patch('os.path.isdir', Mock(return_value=True))
|
||||
@patch('os.unlink', Mock())
|
||||
@patch('os.symlink', Mock())
|
||||
|
||||
Reference in New Issue
Block a user