diff options
Diffstat (limited to 'test/integration')
-rw-r--r-- | test/integration/framework | 4 | ||||
-rwxr-xr-x | test/integration/test-authentication-basic | 10 |
2 files changed, 8 insertions, 6 deletions
diff --git a/test/integration/framework b/test/integration/framework index 40b5bb98b..897ae3bfe 100644 --- a/test/integration/framework +++ b/test/integration/framework @@ -1156,8 +1156,8 @@ rewritesourceslist() { local APTARCHIVE2="copy://$(readlink -f "${TMPWORKINGDIRECTORY}/aptarchive" | sed 's# #%20#g')" for LIST in $(find rootdir/etc/apt/sources.list.d/ -name 'apt-test-*.list'); do sed -i $LIST -e "s#$APTARCHIVE#${1}#" -e "s#$APTARCHIVE2#${1}#" \ - -e "s#http://localhost:${APTHTTPPORT}/#${1}#" \ - -e "s#https://localhost:${APTHTTPSPORT}/#${1}#" + -e "s#http://[^@]*@\?localhost:${APTHTTPPORT}/\?#${1}#" \ + -e "s#https://[^@]*@\?localhost:${APTHTTPSPORT}/\?#${1}#" done } diff --git a/test/integration/test-authentication-basic b/test/integration/test-authentication-basic index 95211ac0e..9a15c7604 100755 --- a/test/integration/test-authentication-basic +++ b/test/integration/test-authentication-basic @@ -9,9 +9,8 @@ configarchitecture 'i386' insertpackage 'unstable' 'foo' 'all' '1' setupaptarchive --no-update -exit -changetohttpswebserver --authorization="$(printf '%s' 'star:hunter2' | base64 )" +changetohttpswebserver --authorization="$(printf '%s' 'star@irc:hunter2' | base64 )" echo 'See, when YOU type hunter2, it shows to us as *******' > aptarchive/bash @@ -62,7 +61,7 @@ runtest() { # good auth authfile 'machine localhost -login star +login star@irc password hunter2' testauthsuccess "$1" @@ -78,7 +77,7 @@ login debian password jessie machine localhost -login star +login star@irc password hunter2' testauthsuccess "$1" } @@ -86,6 +85,9 @@ password hunter2' msgmsg 'server basic auth' rewritesourceslist "http://localhost:${APTHTTPPORT}" runtest "http://localhost:${APTHTTPPORT}" +rewritesourceslist "http://star%40irc:hunter2@localhost:${APTHTTPPORT}" +authfile '' +testauthsuccess "http://star%40irc:hunter2@localhost:${APTHTTPPORT}" rewritesourceslist "https://localhost:${APTHTTPSPORT}" runtest "https://localhost:${APTHTTPSPORT}" rewritesourceslist "http://localhost:${APTHTTPPORT}" |