@@ -504,6 +503,7 @@
Andrea Stirpe <a.stirpe@onestein.nl>
Aitor Bouzas <aitor.bouzas@adaptivecity.com>
Simone Vanin <simone.vanin@agilebg.com>
+
klodr <klodr@users.noreply.github.com>
Vu Nguyen Anh <vuna2004@gmail.com>
Alex Comba <alex.comba@agilebg.com>
diff --git a/auto_backup/tests/test_db_backup.py b/auto_backup/tests/test_db_backup.py
index b7dc6582bc2..1f7d547bab5 100644
--- a/auto_backup/tests/test_db_backup.py
+++ b/auto_backup/tests/test_db_backup.py
@@ -125,6 +125,15 @@ def test_action_backup_local(self):
generated_backup = [f for f in os.listdir(rec_id.folder) if f >= filename]
self.assertEqual(1, len(generated_backup))
+ def test_action_backup_local_list_db_disabled(self):
+ """It should backup locally even when list_db is disabled"""
+ rec_id = self.new_record("local")
+ filename = rec_id.filename(datetime.now())
+ with patch.dict(tools.config.options, {"list_db": False}):
+ rec_id.action_backup()
+ generated_backup = [f for f in os.listdir(rec_id.folder) if f >= filename]
+ self.assertEqual(1, len(generated_backup))
+
def test_action_backup_local_cleanup(self):
"""Backup local database and cleanup old databases"""
rec_id = self.new_record("local")