summaryrefslogtreecommitdiffstats
path: root/test/pacman/tests/replace102.py
blob: ca05d4e65dd2c87bf92c70b7d204a5ff91808906 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
self.description = "Sysupgrade with a versioned replacement, original stays"

sp1 = pmpkg("python2-yaml", "5-1")
sp1.replaces = ["python-yaml<5"]
sp1.conflicts = ["python-yaml<5"]
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)

self.args = "-Su"

self.addrule("PACMAN_RETCODE=0")
self.addrule("!PKG_EXIST=python-yaml")
self.addrule("PKG_VERSION=python2-yaml|5-1")
self.addrule("FILE_EXIST=lib/python2/file")

self.expectfailure = True