summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorNatanael Copa <ncopa@alpinelinux.org>2022-05-18 19:48:32 +0000
committerNatanael Copa <ncopa@alpinelinux.org>2022-05-18 19:48:32 +0000
commit3a6c30ca8d2eb144c625c22040d24b199cfb1587 (patch)
tree69a0238f1792abb96f6c325e3285a626f1d26455 /tests
parent9992890033a99cc65920607aa3bab67510ae20e0 (diff)
downloadalpine-conf-3a6c30ca8d2eb144c625c22040d24b199cfb1587.zip
tests: add test for setup-timezone -z compat
Diffstat (limited to 'tests')
-rwxr-xr-xtests/setup_timezone_test12
1 files changed, 12 insertions, 0 deletions
diff --git a/tests/setup_timezone_test b/tests/setup_timezone_test
index 4154c4e..e6bc402 100755
--- a/tests/setup_timezone_test
+++ b/tests/setup_timezone_test
@@ -5,6 +5,7 @@ init_tests \
setup_timezone_usage \
setup_timezone_copy \
setup_timezone_install \
+ setup_timezone_z_compat
setup_timezone_usage_body() {
test_usage setup-timezone
@@ -33,3 +34,14 @@ setup_timezone_install_body() {
setup-timezone -i Europe/Oslo
}
+setup_timezone_z_compat_body() {
+ init_env
+ mkdir -p usr/share/zoneinfo/Europe
+ touch usr/share/zoneinfo/Europe/Oslo
+ atf_check -s exit:0 \
+ -o match:"apk add .*tzdata" \
+ -o match:"apk del" \
+ -e empty \
+ setup-timezone -z Europe/Oslo
+}
+