mirror of
https://gitlab.alpinelinux.org/alpine/abuild.git
synced 2024-12-23 23:42:35 +00:00
tests: abuild-fetch: test wget failure
This commit is contained in:
parent
0c40d8aca7
commit
c87b6a47fe
@ -6,7 +6,8 @@ init_tests \
|
|||||||
abuild_fetch_curl_invocation \
|
abuild_fetch_curl_invocation \
|
||||||
abuild_fetch_curl_failure \
|
abuild_fetch_curl_failure \
|
||||||
abuild_fetch_curl_insecure \
|
abuild_fetch_curl_insecure \
|
||||||
abuild_fetch_wget_fallback
|
abuild_fetch_wget_fallback \
|
||||||
|
abuild_fetch_wget_failure
|
||||||
|
|
||||||
create_fake_curl() {
|
create_fake_curl() {
|
||||||
mkdir bin
|
mkdir bin
|
||||||
@ -79,3 +80,11 @@ abuild_fetch_wget_fallback_body() {
|
|||||||
abuild-fetch https://example.com/non-existing
|
abuild-fetch https://example.com/non-existing
|
||||||
}
|
}
|
||||||
|
|
||||||
|
abuild_fetch_wget_failure_body() {
|
||||||
|
create_fake_wget
|
||||||
|
WGET_EXITCODE=1 PATH="$PWD/bin:$(atf_get_srcdir)/.." atf_check -s exit:1 \
|
||||||
|
-o match:"Fake wget invoked" \
|
||||||
|
-e empty \
|
||||||
|
abuild-fetch https://example.com/non-existing
|
||||||
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user