]> git.saurik.com Git - apt.git/blob - test/integration/test-apt-get-source-authenticated
test/integration/test-apt-update-filesize-mismatch: use "basename file suffix" instea...
[apt.git] / test / integration / test-apt-get-source-authenticated
1 #!/bin/sh
2 #
3 # Regression test for debian bug #749795. Ensure that we fail with
4 # a error if apt-get source foo will download a source that comes
5 # from a unauthenticated repository
6 #
7 set -e
8
9 TESTDIR=$(readlink -f $(dirname $0))
10 . $TESTDIR/framework
11
12 setupenvironment
13 configarchitecture "i386"
14
15 # a "normal" package with source and binary
16 buildsimplenativepackage 'foo' 'all' '2.0'
17
18 setupaptarchive --no-update
19
20 APTARCHIVE=$(readlink -f ./aptarchive)
21 rm -f $APTARCHIVE/dists/unstable/*Release*
22
23 # update without authenticated InRelease file
24 testwarning aptget update --allow-insecure-repositories
25
26 # this all should fail
27 testfailure aptget install -y foo
28 cd downloaded
29 testfailure aptget source foo
30 testfailure test -e foo_2.0.dsc
31 # allow overriding the warning
32 testsuccess aptget source --allow-unauthenticated foo -o Debug::pkgAcquire::Worker=1
33 testsuccess test -s foo_2.0.dsc -a -L foo_2.0.dsc
34 testaccessrights 'foo_2.0.dsc' '777'