Verify the yum transaction

Check if all packages that were supposed to be installed,
ended up installed.
This commit is contained in:
Martin Gracik 2012-06-04 10:16:06 +02:00
parent 3636fd5814
commit cbe001638e

View File

@ -428,6 +428,13 @@ class LoraxTemplateRunner(object):
self.yum.repos.setProgressBar(LoraxDownloadCallback())
self.yum.processTransaction(callback=LoraxTransactionCallback(),
rpmDisplay=LoraxRpmCallback())
# verify if all packages that were supposed to be installed,
# are really installed
errs = [t.po for t in self.yum.tsInfo if not self.yum.rpmdb.contains(po=t.po)]
for po in errs:
logger.error("package '%s' was not installed", po)
self.yum.closeRpmDB()
def removefrom(self, pkg, *globs):