diff --git a/scripts/commands/RestoreBackupCommand.py b/scripts/commands/RestoreBackupCommand.py index c0153c7..edf56de 100644 --- a/scripts/commands/RestoreBackupCommand.py +++ b/scripts/commands/RestoreBackupCommand.py @@ -14,8 +14,9 @@ class RestoreBackupCommand: dirPairs = [(name, "backup.{0}".format(name)) for name in os.listdir(baseDir) if os.path.isdir(self.__pathProvider.resolveAbsPath(name)) and not name.startswith('backup.')] for pair in dirPairs: - if not os.path.exists(pair[1]): + absPair = (self.__pathProvider.resolveAbsPath(pair[0]), self.__pathProvider.resolveAbsPath(pair[1])) + if not os.path.exists(absPair[1]): continue - shutil.rmtree(pair[0]) # delete src - shutil.copytree(pair[1], pair[0]) # restore from backup + shutil.rmtree(absPair[0]) # delete src + shutil.copytree(absPair[1], absPair[0]) # restore from backup diff --git a/scripts/run_manual_tests.py b/scripts/run_manual_tests.py index 15afad6..5eb4d29 100644 --- a/scripts/run_manual_tests.py +++ b/scripts/run_manual_tests.py @@ -2,5 +2,6 @@ #import ManualTests.info_plist_test #import ManualTests.copy_test #import ManualTests.create_backup_test +#import ManualTests.delete_backup_test -import ManualTests.delete_backup_test \ No newline at end of file +import ManualTests.restore_backup_test \ No newline at end of file