summaryrefslogtreecommitdiffstats
path: root/t/superuser--backtrack-promotion.t
blob: 734715c9712c062eb0db2e07898dde45d8854cd2 (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
26
27
28
29
30
31
32
33
34
35
#!/usr/bin/perl
#
# testcase for bug #52105
#
# a.x86_64 provides b
# a.i586 does not provide b
# c conflicts with b
# d requires a
#
# user has a.x86_64, d installed
# trying to install c has to remove a, d
#
# Original problem:
# urpmi tries to promote a.i586 for d, but strict-arch does not allow it;
# backtracking finds a.i586 as well and tries it again; it still does not
# work, but urpmi already forgot the promotion and does not remove d
#
# This test doesn't work on i586 boxes, just x86_64
#
use strict;
use lib '.', 't';
use helper;
use urpm::util;
use Test::More 'no_plan';

need_root_and_prepare();

my $name = 'backtrack-promotion';
urpmi_addmedia("$name $::pwd/media/$name");

urpmi("--auto --ignorearch a-1-1.x86_64 d");
check_installed_fullnames("a-1-1", "d-1-1");
urpmi("--auto --ignorearch c");
check_installed_fullnames("c-1-1");