]> git.ipfire.org Git - pakfire.git/commitdiff
Re-enable install test after building packages.
authorMichael Tremer <michael.tremer@ipfire.org>
Sun, 7 Aug 2011 09:35:04 +0000 (11:35 +0200)
committerMichael Tremer <michael.tremer@ipfire.org>
Sun, 7 Aug 2011 09:35:04 +0000 (11:35 +0200)
pakfire/base.py
pakfire/builder.py

index 49e8139a27731cb1d1cb8d514e5e3bc542b10124..e19e49edb02e57bc0c559132adf06d109233a5c8 100644 (file)
@@ -209,7 +209,7 @@ class Pakfire(object):
                # Run the transaction.
                t.run()
 
-       def localinstall(self, files):
+       def localinstall(self, files, yes=None):
                repo_name = repo_desc = "localinstall"
 
                # Create a new repository that holds all packages we passed on
@@ -244,8 +244,13 @@ class Pakfire(object):
                                logging.info(_("Nothing to do"))
                                return
 
-                       # Ask the user if this is okay.
-                       if not t.cli_yesno():
+                       if yes is None:
+                               # Ask the user if this is okay.
+                               if not t.cli_yesno():
+                                       return
+                       elif yes:
+                               t.dump()
+                       else:
                                return
 
                        # If okay, run the transcation.
index 8d46926912638854f3528fb328d781655d2d895b..d96acbc254fc7b38e96f6d06b271575302e78f1e 100644 (file)
@@ -324,15 +324,12 @@ class Builder(object):
                transaction.run()
 
        def install_test(self):
-               # XXX currently disabled
-               return
-
                pkgs = []
                for dir, subdirs, files in os.walk(self.chrootPath("result")):
                        for file in files:
                                pkgs.append(os.path.join(dir, file))
 
-               self.pakfire.localinstall(pkgs)
+               self.pakfire.localinstall(pkgs, yes=True)
 
        def chrootPath(self, *args):
                # Remove all leading slashes