def rollback_changes(): """Perform a rollback of changes made during conversion.""" loggerinst = logging.getLogger(__name__) loggerinst.warn("Abnormal exit! Performing rollback ...") subscription.rollback() utils.changed_pkgs_control.restore_pkgs() redhatrelease.system_release_file.restore() subscription.rhn_reg_file.restore() redhatrelease.yum_conf.restore() return
def rollback_changes(): """Perform a rollback of changes made during conversion.""" loggerinst.warn("Abnormal exit! Performing rollback ...") subscription.rollback() utils.changed_pkgs_control.restore_pkgs() repo.restore_yum_repos() redhatrelease.system_release_file.restore() redhatrelease.yum_conf.restore() pkghandler.versionlock_file.restore() return
def rollback_changes(): """Perform a rollback of changes made during conversion.""" loggerinst.warning("Abnormal exit! Performing rollback ...") subscription.rollback() backup.changed_pkgs_control.restore_pkgs() repo.restore_yum_repos() redhatrelease.system_release_file.restore() redhatrelease.os_release_file.restore() special_cases.shim_x64_pkg_protection_file.restore() pkghandler.versionlock_file.restore() system_cert = cert.SystemCert() system_cert.remove() return
def test_rollback(self): subscription.rollback() self.assertEqual(subscription.rollback_renamed_repo_files.called, 1) self.assertEqual(subscription.unregister_system.called, 1)
def test_rollback(self): subscription.rollback() self.assertEqual(subscription.unregister_system.called, 1)