summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDan McGee <dan@archlinux.org>2011-09-19 00:00:21 +0200
committerDan McGee <dan@archlinux.org>2011-09-19 00:00:21 +0200
commit49dff4c80b70f73f55cd8968e83d4ea3727c2ae3 (patch)
tree02e4aa114822f1ec09d0989dc35a73cbef8ad8e0
parent83ee9708b1c0ed3c262e0148ea8cdc880f177d0d (diff)
downloadpacman-49dff4c80b70f73f55cd8968e83d4ea3727c2ae3.tar.gz
pacman-49dff4c80b70f73f55cd8968e83d4ea3727c2ae3.tar.xz
Add a random pactest
Signed-off-by: Dan McGee <dan@archlinux.org>
-rw-r--r--test/pacman/tests/replace104.py25
1 files changed, 25 insertions, 0 deletions
diff --git a/test/pacman/tests/replace104.py b/test/pacman/tests/replace104.py
new file mode 100644
index 00000000..71e698ab
--- /dev/null
+++ b/test/pacman/tests/replace104.py
@@ -0,0 +1,25 @@
+self.description = "Sysupgrade with multiple replaces"
+
+sdep = pmpkg("common-dep", "1.1-1")
+self.addpkg2db("sync", sdep)
+
+for i in range(3):
+ sp = pmpkg("split%d" % i, "2.0-1")
+ sp.depends = ["common-dep"]
+ sp.replaces = ["notsplit"]
+ self.addpkg2db("sync", sp)
+
+ldep = pmpkg("common-dep")
+self.addpkg2db("local", ldep)
+
+lp = pmpkg("notsplit")
+lp.depends = ["common-dep"]
+self.addpkg2db("local", lp)
+
+self.args = "-Su"
+
+self.addrule("PACMAN_RETCODE=0")
+self.addrule("PKG_VERSION=common-dep|1.1-1")
+self.addrule("!PKG_EXIST=notsplit")
+for i in range(3):
+ self.addrule("PKG_VERSION=split%d|2.0-1" % i)