diff --git a/test.sh b/test.sh index 8a1dae3c4..620952d61 100755 --- a/test.sh +++ b/test.sh @@ -48,6 +48,9 @@ function setup_osbs() { cairo-devel gobject-introspection-devel cairo-gobject-devel ostree) PKG_EXTRA+=("${PKG_COMMON_EXTRA[@]}") + python -m venv testenv + source "testenv/bin/activate" + PIP_INST=("$PIP" install --index-url "${PYPI_INDEX:-https://pypi.org/simple}") # RPM install basic dependencies @@ -59,11 +62,9 @@ function setup_osbs() { # Upgrade pip to provide latest features for successful installation $RUN "${PIP_INST[@]}" --upgrade "pip<23.1" + $RUN "${PIP_INST[@]}" -r requirements-build.txt + if [[ $OS == rockylinux ]]; then - # Pip install/upgrade setuptools. Older versions of setuptools don't understand - # environment markers, also rockylinux needs to have setuptools updates to make - # pytest-cov work - $RUN "${PIP_INST[@]}" --upgrade setuptools # install with RPM_PY_SYS=true to avoid error caused by installing on system python $RUN sh -c "RPM_PY_SYS=true ${PIP_INST[*]} rpm-py-installer" fi