-testwebserverlaststatuscode() {
- STATUS="$(mktemp)"
- addtrap "rm $STATUS;"
- msgtest 'Test last status code from the webserver was' "$1"
- downloadfile "http://localhost:8080/_config/find/aptwebserver::last-status-code" "$STATUS" >/dev/null
- if [ "$(cat "$STATUS")" = "$1" ]; then
- msgpass
- else
- cat download-testfile.log
- msgfail "Status was $(cat "$STATUS")"
- fi
-}
-
-