equal
deleted
inserted
replaced
286 def _ensure_test_backup_db_dir(self): |
286 def _ensure_test_backup_db_dir(self): |
287 """Return path of directory for database backup. |
287 """Return path of directory for database backup. |
288 |
288 |
289 The function create it if necessary""" |
289 The function create it if necessary""" |
290 backupdir = join(self.config.apphome, 'database') |
290 backupdir = join(self.config.apphome, 'database') |
291 if not isdir(backupdir): |
291 try: |
292 os.makedirs(backupdir) |
292 os.makedirs(backupdir) |
|
293 except: |
|
294 if not isdir(backupdir): |
|
295 raise |
293 return backupdir |
296 return backupdir |
294 |
297 |
295 def config_path(self, db_id): |
298 def config_path(self, db_id): |
296 """Path for config backup of a given database id""" |
299 """Path for config backup of a given database id""" |
297 return self.absolute_backup_file(db_id, 'config') |
300 return self.absolute_backup_file(db_id, 'config') |