summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorZac Medico <zmedico@gentoo.org>2011-05-21 02:10:57 -0700
committerZac Medico <zmedico@gentoo.org>2011-05-21 02:10:57 -0700
commit8e09dda2ad6afe35bce7d374044a37fd91fafe6e (patch)
treecba0be42cc5bccebeb15cf33bc1cd8094d44f3b0
parent7d43393760af0bce280214c1350c06dd4c586f69 (diff)
downloadportage-8e09dda2ad6afe35bce7d374044a37fd91fafe6e.tar.gz
portage-8e09dda2ad6afe35bce7d374044a37fd91fafe6e.tar.bz2
portage-8e09dda2ad6afe35bce7d374044a37fd91fafe6e.zip
test_merge_order: test circular RDEPEND + DEPEND
-rw-r--r--pym/portage/tests/resolver/test_merge_order.py23
1 files changed, 23 insertions, 0 deletions
diff --git a/pym/portage/tests/resolver/test_merge_order.py b/pym/portage/tests/resolver/test_merge_order.py
index 5ec569a24..df0c3f13b 100644
--- a/pym/portage/tests/resolver/test_merge_order.py
+++ b/pym/portage/tests/resolver/test_merge_order.py
@@ -19,6 +19,16 @@ class MergeOrderTestCase(TestCase):
},
"app-misc/blocker-runtime-a-1" : {},
"app-misc/blocker-runtime-hard-a-1" : {},
+ "app-misc/circ-buildtime-a-0": {},
+ "app-misc/circ-buildtime-a-1": {
+ "RDEPEND": "app-misc/circ-buildtime-b",
+ },
+ "app-misc/circ-buildtime-b-1": {
+ "RDEPEND": "app-misc/circ-buildtime-c",
+ },
+ "app-misc/circ-buildtime-c-1": {
+ "DEPEND": "app-misc/circ-buildtime-a",
+ },
"app-misc/circ-post-runtime-a-1": {
"PDEPEND": "app-misc/circ-post-runtime-b",
},
@@ -48,9 +58,13 @@ class MergeOrderTestCase(TestCase):
"app-misc/some-app-b-1": {
"RDEPEND": "app-misc/circ-post-runtime-a app-misc/circ-post-runtime-b",
},
+ "app-misc/some-app-c-1": {
+ "RDEPEND": "app-misc/circ-buildtime-a app-misc/circ-buildtime-b",
+ },
}
installed = {
+ "app-misc/circ-buildtime-a-0": {},
"app-misc/installed-blocker-a-1" : {
"EAPI" : "2",
"DEPEND" : "!app-misc/blocker-buildtime-a",
@@ -70,6 +84,15 @@ class MergeOrderTestCase(TestCase):
ambigous_merge_order = True,
mergelist = [("app-misc/circ-runtime-c-1", "app-misc/circ-runtime-b-1", "app-misc/circ-runtime-a-1"), "app-misc/some-app-a-1"]),
# Test optimal merge order for a circular dep that is
+ # RDEPEND in one direction and DEPEND in the other.
+ # This requires an installed instance of the DEPEND
+ # package in order to be solvable.
+ ResolverPlaygroundTestCase(
+ ["app-misc/some-app-c", "app-misc/circ-buildtime-a"],
+ success = True,
+ ambigous_merge_order = True,
+ mergelist = [("app-misc/circ-buildtime-b-1", "app-misc/circ-buildtime-c-1"), "app-misc/circ-buildtime-a-1", "app-misc/some-app-c-1"]),
+ # Test optimal merge order for a circular dep that is
# RDEPEND in one direction and PDEPEND in the other.
ResolverPlaygroundTestCase(
["app-misc/some-app-b"],