summaryrefslogtreecommitdiff
path: root/test/integration/test-apt-update-transactions
blob: 24733499181aa7e53c82d02e5f5b16e590bc8b20 (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
#!/bin/sh
set -e

TESTDIR=$(readlink -f $(dirname $0))
. $TESTDIR/framework

setupenvironment
configarchitecture "i386"

insertpackage 'unstable' 'foo' 'all' '1.0'

setupaptarchive --no-update
changetowebserver

# break package file
cat > aptarchive/dists/unstable/main/binary-i386/Packages <<EOF
Package: bar
EOF
compressfile aptarchive/dists/unstable/main/binary-i386/Packages '+1hour'

# ensure that a update will only succeed entirely or not at all
testfailure aptget update
testequal "partial" ls rootdir/var/lib/apt/lists