From 402e13b60ae2563b22b652d749910b625bade92a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Michal=20Posp=C3=AD=C5=A1il?= Date: Mon, 1 Sep 2025 23:16:38 +0200 Subject: [PATCH] set bundled package paths in plan There is a key difference between Fedora and RHEL. Fedora has pcs as a noarch package which causes it to be installed into /usr/lib rather than /usr/lib64. This means that bundled packages have a different path. This caused import errors in tests. There is also a better way of setting the environment variables - through tmt instead of the preparation script. --- plan-gating.fmf | 5 +++++ tests/prepare-tests.sh | 3 --- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/plan-gating.fmf b/plan-gating.fmf index 85d54c3..7442cc0 100644 --- a/plan-gating.fmf +++ b/plan-gating.fmf @@ -1,6 +1,11 @@ summary: PCS gating test plan description: Runs upstream tier0, tier1 and smoke tests +# Always use bundled packages from system +environment: + PYTHONPATH: /usr/lib64/pcs/pcs_bundled/packages/ + GEM_HOME: /usr/lib64/pcsd/vendor/bundle/ + discover: dist-git-source: true dist-git-install-builddeps: true diff --git a/tests/prepare-tests.sh b/tests/prepare-tests.sh index 69d8976..7b592f6 100755 --- a/tests/prepare-tests.sh +++ b/tests/prepare-tests.sh @@ -12,9 +12,6 @@ rm -rfv *SPECPARTS # Remove pcs-web-ui, pcs-*-build for "cd pcs-*" to have exactly one match rm -rf pcs-web-ui-* pcs-*-build cd pcs-*/ -# Run autotools, use bundled dependencies from the system -export PYTHONPATH=/usr/lib/pcs/pcs_bundled/packages/ -export GEM_HOME=/usr/lib/pcsd/vendor/bundle/ ./autogen.sh ./configure --enable-local-build --enable-use-local-cache-only \ --enable-individual-bundling --enable-webui --with-pcs-lib-dir=/usr/lib