summaryrefslogtreecommitdiffstats
path: root/t/superuser--handle-conflict-deps.t
diff options
context:
space:
mode:
authorAnssi Hannula <anssi@mandriva.org>2010-01-23 05:51:38 +0000
committerAnssi Hannula <anssi@mandriva.org>2010-01-23 05:51:38 +0000
commit12fc02682f4a7ba64ae765d925b03946ca46c787 (patch)
treebe9f9585bfeedb4550b8dae214652dbb41ac11c6 /t/superuser--handle-conflict-deps.t
parentb972f890ef8d191ec32ef9e88ce95891c6b0a47f (diff)
downloadurpmi-12fc02682f4a7ba64ae765d925b03946ca46c787.tar
urpmi-12fc02682f4a7ba64ae765d925b03946ca46c787.tar.gz
urpmi-12fc02682f4a7ba64ae765d925b03946ca46c787.tar.bz2
urpmi-12fc02682f4a7ba64ae765d925b03946ca46c787.tar.xz
urpmi-12fc02682f4a7ba64ae765d925b03946ca46c787.zip
testsuite: When trying to install two conflicting packages, consider
the tests passed if either of them is installed succesfully after alerting the user.
Diffstat (limited to 't/superuser--handle-conflict-deps.t')
-rw-r--r--t/superuser--handle-conflict-deps.t14
1 files changed, 12 insertions, 2 deletions
diff --git a/t/superuser--handle-conflict-deps.t b/t/superuser--handle-conflict-deps.t
index 24197604..e5c45a3e 100644
--- a/t/superuser--handle-conflict-deps.t
+++ b/t/superuser--handle-conflict-deps.t
@@ -39,10 +39,20 @@ sub test_conflict_on_upgrade {
sub test_conflict_on_install {
urpmi('--auto a b');
- check_installed_and_remove('b', 'b-sub'); # WARNING: either a or b is chosen, depending on hdlist order
+ # either a or b is chosen, depending on hdlist order; both are valid
+ if (system("rpm -q --quiet --root $::pwd/root a") == 0) {
+ check_installed_and_remove('a');
+ } else {
+ check_installed_and_remove('b', 'b-sub');
+ }
urpmi('--auto f g'); # test for bug #52135
- check_installed_and_remove('f');
+ # either f or g is chosen, depending on hdlist order; both are valid
+ if (system("rpm -q --quiet --root $::pwd/root f") == 0) {
+ check_installed_and_remove('f');
+ } else {
+ check_installed_and_remove('g');
+ }
}
sub test_simple {