summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorSergio Lindo Mansilla <slindomansilla@suse.com>2018-05-18 16:24:36 +0200
committerZbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>2018-05-30 18:13:14 +0200
commitc2f32f616bf0530c5b8198e69144d590f03a17c0 (patch)
treec4412dce888f49783f7203cae2fadc3f792a6eee /test
parente6ebebbe6aef5830793af515c2e3a998bde920b9 (diff)
downloadsystemd-c2f32f616bf0530c5b8198e69144d590f03a17c0.tar.gz
Fix pattern to detect distribution
With operator '=', when in /etc/os-release: ID_LIKE="opensuse suse" # Tumbleweed since at least 2018-04-24 or ID_LIKE="suse opensuse" # Leap 15
Diffstat (limited to 'test')
-rw-r--r--test/test-functions6
1 files changed, 3 insertions, 3 deletions
diff --git a/test/test-functions b/test/test-functions
index cc9b025dca..6535099047 100644
--- a/test/test-functions
+++ b/test/test-functions
@@ -4,9 +4,9 @@
PATH=/sbin:/bin:/usr/sbin:/usr/bin
export PATH
-LOOKS_LIKE_DEBIAN=$(source /etc/os-release && [[ "$ID" = "debian" || "$ID_LIKE" = "debian" ]] && echo yes || true)
-LOOKS_LIKE_ARCH=$(source /etc/os-release && [[ "$ID" = "arch" ]] && echo yes || true)
-LOOKS_LIKE_SUSE=$(source /etc/os-release && [[ "$ID_LIKE" = "suse" ]] && echo yes || true)
+LOOKS_LIKE_DEBIAN=$(source /etc/os-release && [[ "$ID" = "debian" || " $ID_LIKE " = *" debian "* ]] && echo yes || true)
+LOOKS_LIKE_ARCH=$(source /etc/os-release && [[ "$ID" = "arch" || " $ID_LIKE " = *" arch "* ]] && echo yes || true)
+LOOKS_LIKE_SUSE=$(source /etc/os-release && [[ " $ID_LIKE " = *" suse "* ]] && echo yes || true)
KERNEL_VER=${KERNEL_VER-$(uname -r)}
KERNEL_MODS="/lib/modules/$KERNEL_VER/"
QEMU_TIMEOUT="${QEMU_TIMEOUT:-infinity}"