summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNatanael Copa <ncopa@alpinelinux.org>2022-05-19 14:36:27 +0200
committerNatanael Copa <ncopa@alpinelinux.org>2022-05-19 14:36:27 +0200
commitb5564b6c65df806acb198eca3ee13d0c6e4577b1 (patch)
tree584fdb8db9813a1df701bc78503f7bb7296c9129
parentcfd84d0ac9568d62d55fa3b541a0fdcdc3ed6d39 (diff)
downloadalpine-conf-b5564b6c65df806acb198eca3ee13d0c6e4577b1.zip
tests: add test for setup-xorg-base
-rwxr-xr-xtests/setup_xorg_base_test22
1 files changed, 22 insertions, 0 deletions
diff --git a/tests/setup_xorg_base_test b/tests/setup_xorg_base_test
new file mode 100755
index 0000000..b661035
--- /dev/null
+++ b/tests/setup_xorg_base_test
@@ -0,0 +1,22 @@
+#!/usr/bin/env atf-sh
+
+. $(atf_get_srcdir)/test_env.sh
+init_tests \
+ setup_xorg_base_usage \
+ setup_xorg_base
+
+setup_xorg_base_usage_body() {
+ test_usage setup-xorg-base
+}
+
+setup_xorg_base_body() {
+ init_env
+ mkdir -p etc/apk
+ echo "https://dl-cdn.alpinelinux.org/alpine/edge/main" > etc/apk/repositories
+
+ atf_check -s exit:0 \
+ -o match:"apk add.*xorg-server.*foobar" \
+ -o match:"Starting udev" \
+ -e empty \
+ setup-xorg-base foobar
+}