summaryrefslogtreecommitdiffstats
path: root/t
diff options
context:
space:
mode:
authorPascal Rigaux <pixel@mandriva.com>2007-09-12 16:52:59 +0000
committerPascal Rigaux <pixel@mandriva.com>2007-09-12 16:52:59 +0000
commit9e176a88eb8349c7fe7909ae8f4cdb9846aa6bf7 (patch)
tree0c44a233482300b29f0066d956cd3aa9a6b98eb7 /t
parent95d113923b67b660592b2f6d0db188447c5a3403 (diff)
downloadurpmi-9e176a88eb8349c7fe7909ae8f4cdb9846aa6bf7.tar
urpmi-9e176a88eb8349c7fe7909ae8f4cdb9846aa6bf7.tar.gz
urpmi-9e176a88eb8349c7fe7909ae8f4cdb9846aa6bf7.tar.bz2
urpmi-9e176a88eb8349c7fe7909ae8f4cdb9846aa6bf7.tar.xz
urpmi-9e176a88eb8349c7fe7909ae8f4cdb9846aa6bf7.zip
add a test case (to detect breakage in perl-URPM)
Diffstat (limited to 't')
-rw-r--r--t/superuser--handle-conflict-deps.t20
1 files changed, 14 insertions, 6 deletions
diff --git a/t/superuser--handle-conflict-deps.t b/t/superuser--handle-conflict-deps.t
index dcef7d03..21b628ab 100644
--- a/t/superuser--handle-conflict-deps.t
+++ b/t/superuser--handle-conflict-deps.t
@@ -1,7 +1,5 @@
#!/usr/bin/perl
-# test from bugs #12696, #11885
-#
# b requires b-sub
# a-sup requires a
# a conflicts with b, b conflicts with a
@@ -16,8 +14,18 @@ need_root_and_prepare();
my $name = 'handle-conflict-deps';
urpmi_addmedia("$name $::pwd/media/$name");
-urpmi('--auto a-sup');
-check_installed_names('a', 'a-sup');
+test_conflict_on_install();
+test_conflict_on_upgrade(); #test from bugs #12696, #11885
-urpmi('--auto b');
-check_installed_names('b', 'b-sub');
+sub test_conflict_on_upgrade {
+ urpmi('--auto a-sup');
+ check_installed_names('a', 'a-sup');
+
+ urpmi('--auto b');
+ check_installed_and_remove('b', 'b-sub');
+}
+
+sub test_conflict_on_install {
+ urpmi('--auto a b');
+ check_installed_and_remove('a'); # WARNING: why does it choose one or the other?
+}