summaryrefslogtreecommitdiffstats
path: root/test
diff options
context:
space:
mode:
authorDaan De Meyer <daan.j.demeyer@gmail.com>2025-01-08 10:38:21 +0100
committerDaan De Meyer <daan.j.demeyer@gmail.com>2025-01-08 11:15:43 +0100
commitfc1b08dee2ccf706580fa448e66831d1e853d054 (patch)
tree92ecd301fafebe6fdee0e0d75b0d3384d329a88c /test
parentfmf: Fix dist-git example (diff)
downloadsystemd-fc1b08dee2ccf706580fa448e66831d1e853d054.tar.xz
systemd-fc1b08dee2ccf706580fa448e66831d1e853d054.zip
fmf: Fix glob
Globs inside quotes aren't expanded and we need the glob to be more specific to avoid matching multiple entries inside the tmt source directory.
Diffstat (limited to 'test')
-rwxr-xr-xtest/fmf/integration-tests/test.sh5
1 files changed, 4 insertions, 1 deletions
diff --git a/test/fmf/integration-tests/test.sh b/test/fmf/integration-tests/test.sh
index 73771d4237..0a1595fa97 100755
--- a/test/fmf/integration-tests/test.sh
+++ b/test/fmf/integration-tests/test.sh
@@ -23,8 +23,11 @@ setenforce 0 || true
# execute:
# how: tmt
+shopt -s extglob
+
if [[ -n "${TMT_SOURCE_DIR:-}" ]]; then
- pushd "$TMT_SOURCE_DIR/*/"
+ # Match either directories ending with branch names (e.g. systemd-fmf) or releases (e.g systemd-257.1).
+ pushd "$TMT_SOURCE_DIR"/systemd-+([0-9a-z.~])/
elif [[ -n "${PACKIT_TARGET_URL:-}" ]]; then
# Prepare systemd source tree
git clone "$PACKIT_TARGET_URL" systemd --branch "$PACKIT_TARGET_BRANCH"