summaryrefslogtreecommitdiff
path: root/test/integration/test-apt-update-transactions
blob: ee8d20dbf11073d4e398ed3ab5374bfe96e6d6fe (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
#!/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