aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAvatar Ciaran McCreesh <ciaran.mccreesh@googlemail.com> 2006-02-05 01:39:15 +0000
committerAvatar Ciaran McCreesh <ciaran.mccreesh@googlemail.com> 2006-02-05 01:39:15 +0000
commit218166b38038b0734017b8e46203473eabbea8d6 (patch)
treec126ad580cbb490d26ce0f14c7527ece47530fb5
parent0d6e6c165f36f26f35e92d12440079cadfbdb020 (diff)
downloadpaludis-218166b38038b0734017b8e46203473eabbea8d6.tar.gz
paludis-218166b38038b0734017b8e46203473eabbea8d6.tar.xz
Add use?, !use? dep atom tests
-rw-r--r--paludis/dep_list_TEST.cc82
1 files changed, 82 insertions, 0 deletions
diff --git a/paludis/dep_list_TEST.cc b/paludis/dep_list_TEST.cc
index bd6ac6c..c8e206f 100644
--- a/paludis/dep_list_TEST.cc
+++ b/paludis/dep_list_TEST.cc
@@ -533,6 +533,88 @@ namespace test_cases
} test_dep_list_18;
/**
+ * \test Test DepList resolution behaviour.
+ *
+ * \ingroup Test
+ */
+ struct DepListTestCase19 : DepListTestCase<19>
+ {
+ void populate_repo()
+ {
+ repo->add_version("cat", "one", "1")->set(vmk_depend, "enabled? ( cat/two )");
+ repo->add_version("cat", "two", "1");
+ }
+
+ void populate_expected()
+ {
+ merge_target = "cat/one";
+ expected.push_back("cat/two-1:0::repo");
+ expected.push_back("cat/one-1:0::repo");
+ }
+ } test_dep_list_19;
+
+ /**
+ * \test Test DepList resolution behaviour.
+ *
+ * \ingroup Test
+ */
+ struct DepListTestCase20 : DepListTestCase<20>
+ {
+ void populate_repo()
+ {
+ repo->add_version("cat", "one", "1")->set(vmk_depend, "!enabled? ( cat/two )");
+ repo->add_version("cat", "two", "1");
+ }
+
+ void populate_expected()
+ {
+ merge_target = "cat/one";
+ expected.push_back("cat/one-1:0::repo");
+ }
+ } test_dep_list_20;
+
+ /**
+ * \test Test DepList resolution behaviour.
+ *
+ * \ingroup Test
+ */
+ struct DepListTestCase21 : DepListTestCase<21>
+ {
+ void populate_repo()
+ {
+ repo->add_version("cat", "one", "1")->set(vmk_depend, "disabled? ( cat/two )");
+ repo->add_version("cat", "two", "1");
+ }
+
+ void populate_expected()
+ {
+ merge_target = "cat/one";
+ expected.push_back("cat/one-1:0::repo");
+ }
+ } test_dep_list_21;
+
+ /**
+ * \test Test DepList resolution behaviour.
+ *
+ * \ingroup Test
+ */
+ struct DepListTestCase22 : DepListTestCase<22>
+ {
+ void populate_repo()
+ {
+ repo->add_version("cat", "one", "1")->set(vmk_depend, "!disabled? ( cat/two )");
+ repo->add_version("cat", "two", "1");
+ }
+
+ void populate_expected()
+ {
+ merge_target = "cat/one";
+ expected.push_back("cat/two-1:0::repo");
+ expected.push_back("cat/one-1:0::repo");
+ }
+ } test_dep_list_22;
+
+ /**
* \test Test DepList transactional add behaviour.
*
* \ingroup Test