Don't use pytest-xdist in ELN

pytest-xdist is unwanted in ELN, this package brought it in.
This commit is contained in:
Miro Hrončok 2023-10-16 14:02:13 +02:00
parent 89fce220b6
commit 29588c2967

View File

@ -66,12 +66,14 @@ find -type f -name '*.py' -exec sed \
# Fedora does not run coverage tests. # Fedora does not run coverage tests.
# mock is deprecated in Fedora. We use unittest.mock. # mock is deprecated in Fedora. We use unittest.mock.
# pip-tools is not used directly by the unit tests. # pip-tools is not used directly by the unit tests.
# pytest-xdist is unwanted in RHEL.
sed \ sed \
-e 's|==.*||' \ -e 's|==.*||' \
-e '/coverage/d' \ -e '/coverage/d' \
-e '/mock/d' \ -e '/mock/d' \
-e '/pip-tools/d' \ -e '/pip-tools/d' \
-e '/pytest-cov/d' \ -e '/pytest-cov/d' \
%{?rhel:-e '/pytest-xdist/d'} \
requirements-test.txt > _requirements-test.txt requirements-test.txt > _requirements-test.txt
@ -107,7 +109,7 @@ export TESTS_REMOVE_REPO_ROOT_FROM_PATH=1 TZ=UTC
%if 0%{?rhel} %if 0%{?rhel}
export OPENSSL_ENABLE_SHA1_SIGNATURES=yes export OPENSSL_ENABLE_SHA1_SIGNATURES=yes
%endif %endif
%pytest --verbose --numprocesses=auto --dist=loadfile tests/unit tests/functional %pytest --verbose %{!?rhel:--numprocesses=auto --dist=loadfile} tests/unit tests/functional
%files -f %{pyproject_files} %files -f %{pyproject_files}