]> git.saurik.com Git - apt.git/blame - test/integration/test-apt-get-upgrade
merge debian/sid into debian/experimental
[apt.git] / test / integration / test-apt-get-upgrade
CommitLineData
08d3d7e9
MV
1#!/bin/sh
2set -e
3
4TESTDIR=$(readlink -f $(dirname $0))
5. $TESTDIR/framework
6
7setupenvironment
8configarchitecture "i386"
9
60b3bf0c 10# simple case
10e100e5 11insertpackage 'stable,installed' 'upgrade-simple' 'all' '1.0'
60b3bf0c 12insertpackage 'unstable' 'upgrade-simple' 'all' '2.0'
08d3d7e9 13
60b3bf0c 14# upgrade with a new dependency
10e100e5 15insertpackage 'stable,installed' 'upgrade-with-new-dep' 'all' '1.0'
60b3bf0c
MV
16insertpackage 'unstable' 'upgrade-with-new-dep' 'all' '2.0' 'Depends: new-dep'
17insertpackage 'stable' 'new-dep' 'all' '1.0'
08d3d7e9 18
60b3bf0c 19# upgrade with conflict and a new pkg with higher priority than conflict
10e100e5 20insertpackage 'stable,installed' 'upgrade-with-conflict' 'all' '1.0'
60b3bf0c 21insertpackage 'unstable' 'upgrade-with-conflict' 'all' '2.0' 'Conflicts: conflicting-dep' 'standard'
10e100e5 22insertpackage 'stable,installed' 'conflicting-dep' 'all' '1.0'
08d3d7e9
MV
23
24setupaptarchive
25
d029b718 26# Test if normal upgrade works as expected
08d3d7e9
MV
27testequal 'Reading package lists...
28Building dependency tree...
2a884c61 29Calculating upgrade...
08d3d7e9 30The following packages have been kept back:
60b3bf0c 31 upgrade-with-conflict upgrade-with-new-dep
08d3d7e9 32The following packages will be upgraded:
60b3bf0c 33 upgrade-simple
08d3d7e9 341 upgraded, 0 newly installed, 0 to remove and 2 not upgraded.
60b3bf0c 35Inst upgrade-simple [1.0] (2.0 unstable [all])
d029b718 36Conf upgrade-simple (2.0 unstable [all])' aptget -s upgrade
08d3d7e9 37
d029b718 38# Test if apt-get upgrade --with-new-pkgs works
08d3d7e9
MV
39testequal 'Reading package lists...
40Building dependency tree...
2a884c61 41Calculating upgrade...
08d3d7e9 42The following NEW packages will be installed:
60b3bf0c 43 new-dep
08d3d7e9 44The following packages have been kept back:
60b3bf0c 45 upgrade-with-conflict
08d3d7e9 46The following packages will be upgraded:
60b3bf0c
MV
47 upgrade-simple upgrade-with-new-dep
482 upgraded, 1 newly installed, 0 to remove and 1 not upgraded.
49Inst new-dep (1.0 stable [all])
50Inst upgrade-simple [1.0] (2.0 unstable [all])
51Inst upgrade-with-new-dep [1.0] (2.0 unstable [all])
52Conf new-dep (1.0 stable [all])
53Conf upgrade-simple (2.0 unstable [all])
d029b718 54Conf upgrade-with-new-dep (2.0 unstable [all])' aptget -s upgrade --with-new-pkgs
08d3d7e9 55
d029b718 56# Test if apt-get dist-upgrade works
08d3d7e9
MV
57testequal 'Reading package lists...
58Building dependency tree...
2a884c61 59Calculating upgrade...
60b3bf0c
MV
60The following packages will be REMOVED:
61 conflicting-dep
08d3d7e9 62The following NEW packages will be installed:
60b3bf0c 63 new-dep
08d3d7e9 64The following packages will be upgraded:
60b3bf0c
MV
65 upgrade-simple upgrade-with-conflict upgrade-with-new-dep
663 upgraded, 1 newly installed, 1 to remove and 0 not upgraded.
67Remv conflicting-dep [1.0]
68Inst upgrade-with-conflict [1.0] (2.0 unstable [all])
69Inst new-dep (1.0 stable [all])
70Inst upgrade-simple [1.0] (2.0 unstable [all])
71Inst upgrade-with-new-dep [1.0] (2.0 unstable [all])
72Conf upgrade-with-conflict (2.0 unstable [all])
73Conf new-dep (1.0 stable [all])
74Conf upgrade-simple (2.0 unstable [all])
d029b718 75Conf upgrade-with-new-dep (2.0 unstable [all])' aptget -s dist-upgrade
08d3d7e9 76