[pacman-dev] [PATCH] Add a slightly simpler versioned replace test

Dan McGee dan at archlinux.org
Tue Aug 9 16:45:16 EDT 2011


It turns out we have a few problems here which are best tackled
independently. The first is simply parsing replacements as dep strings;
the second will be dealing with replaces when the original package name
still exists in the repository.

Signed-off-by: Dan McGee <dan at archlinux.org>
---

Note the commit diffstat looks a bit weird (as does the diff); I just wanted to
have two very similar tests numbered next to each other so I moved the next one
up to the next block of 10. 101 and 102 are almost the same; the only
difference is the to be replaced package is still in the repos in 102 (albeit a
newer version).

-Dan

 test/pacman/tests/replace101.py                    |    7 +------
 test/pacman/tests/{replace101.py => replace102.py} |    2 +-
 test/pacman/tests/{replace102.py => replace110.py} |    0
 3 files changed, 2 insertions(+), 7 deletions(-)
 copy test/pacman/tests/{replace101.py => replace102.py} (88%)
 rename test/pacman/tests/{replace102.py => replace110.py} (100%)

diff --git a/test/pacman/tests/replace101.py b/test/pacman/tests/replace101.py
index 86c40ac..ee0f860 100644
--- a/test/pacman/tests/replace101.py
+++ b/test/pacman/tests/replace101.py
@@ -1,4 +1,4 @@
-self.description = "Sysupgrade with a versioned replacement"
+self.description = "Sysupgrade with a versioned replacement, original disappears"
 
 sp1 = pmpkg("python2-yaml", "5-1")
 sp1.replaces = ["python-yaml<5"]
@@ -6,11 +6,6 @@
 sp1.files = ["lib/python2/file"]
 self.addpkg2db("sync", sp1)
 
-# the python3 version
-sp2 = pmpkg("python-yaml", "5-1")
-sp2.files = ["lib/python3/file"]
-self.addpkg2db("sync", sp2)
-
 lp1 = pmpkg("python-yaml", "4-1")
 lp1.files = ["lib/python2/file"]
 self.addpkg2db("local", lp1)
diff --git a/test/pacman/tests/replace101.py b/test/pacman/tests/replace102.py
similarity index 88%
copy from test/pacman/tests/replace101.py
copy to test/pacman/tests/replace102.py
index 86c40ac..ca05d4e 100644
--- a/test/pacman/tests/replace101.py
+++ b/test/pacman/tests/replace102.py
@@ -1,4 +1,4 @@
-self.description = "Sysupgrade with a versioned replacement"
+self.description = "Sysupgrade with a versioned replacement, original stays"
 
 sp1 = pmpkg("python2-yaml", "5-1")
 sp1.replaces = ["python-yaml<5"]
diff --git a/test/pacman/tests/replace102.py b/test/pacman/tests/replace110.py
similarity index 100%
rename from test/pacman/tests/replace102.py
rename to test/pacman/tests/replace110.py
-- 
1.7.6



More information about the pacman-dev mailing list