From ae40d1c05b2a164e922a19ddece1334bf5e55330 Mon Sep 17 00:00:00 2001 From: Allan McRae Date: Thu, 3 Apr 2008 16:35:14 +1000 Subject: Pactest for removing multiple items in a dependency chain. This adds a test for when removing multilpe packages recursively from a chain of dependent packages. This situation can occur when removing installed dependencies with makepkg if a "makedepend" recursively depends on a "depend" or if redundant dependancies are included. Signed-off-by: Allan McRae Signed-off-by: Xavier Chantry Signed-off-by: Dan McGee --- pactest/tests/remove052.py | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) create mode 100644 pactest/tests/remove052.py (limited to 'pactest/tests') diff --git a/pactest/tests/remove052.py b/pactest/tests/remove052.py new file mode 100644 index 00000000..df1e0db1 --- /dev/null +++ b/pactest/tests/remove052.py @@ -0,0 +1,21 @@ +self.description = "-Rs test (dependency chain)" + +lp1 = pmpkg("pkg1") +lp1.depends = ["pkg2"] +self.addpkg2db("local", lp1) + +lp2 = pmpkg("pkg2") +lp2.depends = ["pkg3"] +lp2.reason = 1 +self.addpkg2db("local", lp2) + +lp3 = pmpkg("pkg3") +lp3.reason = 1 +self.addpkg2db("local", lp3) + +self.args = "-Rs %s" % " ".join([p.name for p in lp1, lp3]) + +self.addrule("PACMAN_RETCODE=0") +self.addrule("!PKG_EXIST=pkg1") +self.addrule("!PKG_EXIST=pkg2") +self.addrule("!PKG_EXIST=pkg3") -- cgit v1.2.3-70-g09d2