123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226 |
- #!/bin/sh
- set -e
- TESTDIR="$(readlink -f "$(dirname "$0")")"
- . "$TESTDIR/framework"
- setupenvironment
- configarchitecture 'i386' 'amd64'
- buildsimplenativepackage 'libc6' 'i386' '1.0' 'stable'
- buildsimplenativepackage 'libc6' 'amd64' '1.0' 'stable'
- buildsimplenativepackage 'libc6' 'all' '2.0' 'testing'
- buildsimplenativepackage 'foobar' 'i386' '1.0' 'stable' 'Depends: libc6'
- buildsimplenativepackage 'foobar' 'amd64' '1.0' 'stable' 'Depends: libc6'
- setupaptarchive
- testsuccess aptget install libc6:i386 -t stable -y
- testdpkginstalled libc6:i386
- testsuccessequal 'Reading package lists...
- Building dependency tree...
- Reading state information...
- The following packages will be REMOVED:
- libc6
- The following NEW packages will be installed:
- libc6:amd64
- 0 upgraded, 1 newly installed, 1 to remove and 0 not upgraded.
- Remv libc6 [1.0]
- Inst libc6:amd64 (1.0 stable [amd64])
- Conf libc6:amd64 (1.0 stable [amd64])' aptget install libc6:amd64 -s -t stable
- testsuccessequal 'Reading package lists...
- Building dependency tree...
- Reading state information...
- The following NEW packages will be installed:
- foobar
- 0 upgraded, 1 newly installed, 0 to remove and 0 not upgraded.
- Inst foobar (1.0 stable [i386])
- Conf foobar (1.0 stable [i386])' aptget install foobar -st stable
- testsuccessequal 'Reading package lists...
- Building dependency tree...
- Reading state information...
- The following additional packages will be installed:
- libc6:amd64
- The following packages will be REMOVED:
- libc6
- The following NEW packages will be installed:
- foobar:amd64 libc6:amd64
- 0 upgraded, 2 newly installed, 1 to remove and 0 not upgraded.
- Remv libc6 [1.0]
- Inst libc6:amd64 (1.0 stable [amd64])
- Inst foobar:amd64 (1.0 stable [amd64])
- Conf libc6:amd64 (1.0 stable [amd64])
- Conf foobar:amd64 (1.0 stable [amd64])' aptget install foobar:amd64 -st stable
- testsuccessequal "Reading package lists...
- Building dependency tree...
- Reading state information...
- Selected version '1.0' (stable [i386]) for 'foobar'
- The following NEW packages will be installed:
- foobar
- The following packages will be upgraded:
- libc6
- 1 upgraded, 1 newly installed, 0 to remove and 0 not upgraded.
- Inst libc6 [1.0] (2.0 testing [all])
- Inst foobar (1.0 stable [i386])
- Conf libc6 (2.0 testing [all])
- Conf foobar (1.0 stable [i386])" aptget install foobar/stable libc6 -st testing
- testsuccessequal 'Reading package lists...
- Building dependency tree...
- Reading state information...
- Calculating upgrade...
- The following packages will be upgraded:
- libc6
- 1 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
- Inst libc6 [1.0] (2.0 testing [all])
- Conf libc6 (2.0 testing [all])' aptget upgrade -t testing -s
- # FIXME: on amd64 systems this test wouldn't run with a real upgrade
- # as APT (here i386) disagree about the native architecture, so
- # we fake it here:
- #aptget upgrade -y -qq >/dev/null 2>&1
- testsuccess aptget purge libc6 -y
- testsuccess aptget install libc6:i386 -y
- testdpkginstalled libc6:all
- testsuccessequal "Reading package lists...
- Building dependency tree...
- Reading state information...
- Selected version '1.0' (stable [i386]) for 'foobar'
- The following NEW packages will be installed:
- foobar
- 0 upgraded, 1 newly installed, 0 to remove and 0 not upgraded.
- Inst foobar (1.0 stable [i386])
- Conf foobar (1.0 stable [i386])" aptget install foobar/stable -st testing
- testsuccessequal "Reading package lists...
- Building dependency tree...
- Reading state information...
- Selected version '1.0' (stable [amd64]) for 'foobar:amd64'
- The following additional packages will be installed:
- libc6:amd64
- The following packages will be REMOVED:
- libc6
- The following NEW packages will be installed:
- foobar:amd64 libc6:amd64
- 0 upgraded, 2 newly installed, 1 to remove and 0 not upgraded.
- Remv libc6 [2.0]
- Inst libc6:amd64 (1.0 stable [amd64])
- Inst foobar:amd64 (1.0 stable [amd64])
- Conf libc6:amd64 (1.0 stable [amd64])
- Conf foobar:amd64 (1.0 stable [amd64])" aptget install foobar:amd64/stable -st testing
- testsuccessequal "Reading package lists...
- Building dependency tree...
- Reading state information...
- Selected version '1.0' (stable [i386]) for 'libc6'
- The following packages will be DOWNGRADED:
- libc6
- 0 upgraded, 0 newly installed, 1 downgraded, 0 to remove and 0 not upgraded.
- Inst libc6 [2.0] (1.0 stable [i386])
- Conf libc6 (1.0 stable [i386])" aptget install libc6/stable -s
- buildsimplenativepackage 'libc6-same' 'i386' '1.0' 'stable' 'Multi-Arch: same'
- buildsimplenativepackage 'libc6-same' 'amd64' '1.0' 'stable' 'Multi-Arch: same'
- buildsimplenativepackage 'libc6-same' 'all' '2.0' 'testing'
- buildsimplenativepackage 'foobar-same' 'i386' '1.0' 'stable' 'Depends: libc6-same'
- buildsimplenativepackage 'foobar-same' 'amd64' '1.0' 'stable' 'Depends: libc6-same'
- setupaptarchive
- testsuccess aptget install libc6-same:i386 -t stable -y
- testdpkginstalled libc6-same:i386
- testsuccessequal 'Reading package lists...
- Building dependency tree...
- Reading state information...
- The following NEW packages will be installed:
- foobar-same
- 0 upgraded, 1 newly installed, 0 to remove and 0 not upgraded.
- Inst foobar-same (1.0 stable [i386])
- Conf foobar-same (1.0 stable [i386])' aptget install foobar-same -st stable
- testsuccessequal 'Reading package lists...
- Building dependency tree...
- Reading state information...
- The following additional packages will be installed:
- libc6-same:amd64
- The following NEW packages will be installed:
- foobar-same:amd64 libc6-same:amd64
- 0 upgraded, 2 newly installed, 0 to remove and 0 not upgraded.
- Inst libc6-same:amd64 (1.0 stable [amd64])
- Inst foobar-same:amd64 (1.0 stable [amd64])
- Conf libc6-same:amd64 (1.0 stable [amd64])
- Conf foobar-same:amd64 (1.0 stable [amd64])' aptget install foobar-same:amd64 -st stable
- testsuccessequal 'Reading package lists...
- Building dependency tree...
- Reading state information...
- The following NEW packages will be installed:
- libc6-same:amd64
- 0 upgraded, 1 newly installed, 0 to remove and 0 not upgraded.
- Inst libc6-same:amd64 (1.0 stable [amd64])
- Conf libc6-same:amd64 (1.0 stable [amd64])' aptget install libc6-same:amd64 -s -t stable
- # FIXME: We should test installing libc6-same:amd64 here, but dpkg doesn't allow it currently
- testsuccessequal 'Reading package lists...
- Building dependency tree...
- Reading state information...
- Calculating upgrade...
- The following packages will be upgraded:
- libc6-same
- 1 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
- Inst libc6-same [1.0] (2.0 testing [all])
- Conf libc6-same (2.0 testing [all])' aptget upgrade -t testing -s
- # FIXME: on amd64 systems this test wouldn't run with a real upgrade
- # as APT (here i386) disagree about the native architecture, so
- # we fake it here:
- #aptget upgrade -y -qq >/dev/null 2>&1
- testsuccess aptget purge libc6-same -y
- testsuccess aptget install libc6-same:i386 -y
- testdpkginstalled libc6-same:all
- testsuccessequal "Reading package lists...
- Building dependency tree...
- Reading state information...
- Selected version '1.0' (stable [i386]) for 'libc6-same'
- The following packages will be DOWNGRADED:
- libc6-same
- 0 upgraded, 0 newly installed, 1 downgraded, 0 to remove and 0 not upgraded.
- Inst libc6-same [2.0] (1.0 stable [i386])
- Conf libc6-same (1.0 stable [i386])" aptget install libc6-same/stable -s
- testsuccessequal "Reading package lists...
- Building dependency tree...
- Reading state information...
- Selected version '1.0' (stable [i386]) for 'foobar-same'
- The following NEW packages will be installed:
- foobar-same
- 0 upgraded, 1 newly installed, 0 to remove and 0 not upgraded.
- Inst foobar-same (1.0 stable [i386])
- Conf foobar-same (1.0 stable [i386])" aptget install foobar-same/stable -st testing
- testsuccessequal "Reading package lists...
- Building dependency tree...
- Reading state information...
- Selected version '1.0' (stable [amd64]) for 'foobar-same:amd64'
- The following additional packages will be installed:
- libc6-same:amd64
- The following packages will be REMOVED:
- libc6-same
- The following NEW packages will be installed:
- foobar-same:amd64 libc6-same:amd64
- 0 upgraded, 2 newly installed, 1 to remove and 0 not upgraded.
- Remv libc6-same [2.0]
- Inst libc6-same:amd64 (1.0 stable [amd64])
- Inst foobar-same:amd64 (1.0 stable [amd64])
- Conf libc6-same:amd64 (1.0 stable [amd64])
- Conf foobar-same:amd64 (1.0 stable [amd64])" aptget install foobar-same:amd64/stable -st testing
|