Send patches - preferably formatted by git format-patch - to patches at archlinux32 dot org.
summaryrefslogtreecommitdiff
path: root/test/pacman/tests/provision004.py
diff options
context:
space:
mode:
authorDan McGee <dan@archlinux.org>2011-01-22 16:22:01 -0600
committerDan McGee <dan@archlinux.org>2011-01-22 16:29:32 -0600
commit6e71922e6c918de9b60d2e9b1585835421738437 (patch)
tree7964971becba36d3eda9c972b4805e4ec8d97386 /test/pacman/tests/provision004.py
parenta99e7272b8703e54b3c96ac0fdb7fe7eacfabbe8 (diff)
Add a few new provides tests
These deal with already-installed packages and how they should be the preferred provider in cases where provider selection now occurs. A few involve multiple sync repos. Signed-off-by: Dan McGee <dan@archlinux.org>
Diffstat (limited to 'test/pacman/tests/provision004.py')
-rw-r--r--test/pacman/tests/provision004.py21
1 files changed, 21 insertions, 0 deletions
diff --git a/test/pacman/tests/provision004.py b/test/pacman/tests/provision004.py
new file mode 100644
index 00000000..696fa79f
--- /dev/null
+++ b/test/pacman/tests/provision004.py
@@ -0,0 +1,21 @@
+self.description = "-S literal with provision of same name installed"
+
+sp = pmpkg("provision", "1.0-2")
+sp.provides = ["literal"]
+sp.conflicts = ["literal"]
+self.addpkg2db("sync", sp)
+
+sp = pmpkg("literal", "1.0-2")
+self.addpkg2db("sync2", sp)
+
+lp = pmpkg("provision")
+lp.provides = ["literal"]
+lp.conflicts = ["literal"]
+self.addpkg2db("local", lp)
+
+self.args = "-S literal --ask=4"
+
+self.addrule("PACMAN_RETCODE=0")
+self.addrule("!PKG_EXIST=provision")
+self.addrule("PKG_EXIST=literal")
+self.addrule("PKG_VERSION=literal|1.0-2")