1
0
Fork 0
apt/test/integration/test-apt-redirect-loop
Daniel Baumann 6810ba718b
Adding upstream version 3.0.2.
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
2025-06-20 21:10:43 +02:00

20 lines
788 B
Bash
Executable file

#!/bin/sh
set -e
TESTDIR="$(readlink -f "$(dirname "$0")")"
. "$TESTDIR/framework"
setupenvironment
configarchitecture "i386"
echo 'alright' > aptarchive/working
changetohttpswebserver
webserverconfig 'aptwebserver::redirect::replace::/redirectme3/' '/redirectme/'
webserverconfig 'aptwebserver::redirect::replace::/redirectme2/' '/redirectme3/'
webserverconfig 'aptwebserver::redirect::replace::/redirectme/' '/redirectme2/'
testfailure apthelper download-file "http://localhost:${APTHTTPPORT}/redirectme/working" httpfile
testsuccess grep 'Redirection loop encountered' rootdir/tmp/testfailure.output
testfailure apthelper download-file "https://localhost:${APTHTTPSPORT}/redirectme/working" httpsfile
testsuccess grep 'Redirection loop encountered' rootdir/tmp/testfailure.output