]> git.saurik.com Git - apt.git/blame - test/integration/test-apt-get-update-unauth-warning
Do not allow going from authenticated to unauthenticated repo
[apt.git] / test / integration / test-apt-get-update-unauth-warning
CommitLineData
c4ffa042
MV
1#!/bin/sh
2#
3# ensure we print warnings for unauthenticated repositories
4#
5set -e
6
7TESTDIR=$(readlink -f $(dirname $0))
8. $TESTDIR/framework
9
10setupenvironment
11configarchitecture "i386"
12
13# a "normal" package with source and binary
14buildsimplenativepackage 'foo' 'all' '2.0'
15
16setupaptarchive --no-update
17
18APTARCHIVE=$(readlink -f ./aptarchive)
19rm -f $APTARCHIVE/dists/unstable/*Release*
20
21# update without authenticated InRelease file
22testequal "Ign file: unstable InRelease
23Ign file: unstable Release
24Reading package lists...
25W: The data from 'file: unstable Release' is not signed. Packages from that repository can not be authenticated." aptget update
26
27# ensure we can not install the package
28testequal "WARNING: The following packages cannot be authenticated!
29 foo
30E: There are problems and -y was used without --force-yes" aptget install -qq -y foo