[packages/python-pyfakefs] - fix tests with pyfakefs already installed

qboosh qboosh at pld-linux.org
Thu May 14 15:29:55 CEST 2020


commit c45d0be8af1d42c06e14ef16fd74050e09105b95
Author: Jakub Bogusz <qboosh at pld-linux.org>
Date:   Thu May 14 15:30:25 2020 +0200

    - fix tests with pyfakefs already installed

 python-pyfakefs.spec | 13 +++++++++----
 1 file changed, 9 insertions(+), 4 deletions(-)
---
diff --git a/python-pyfakefs.spec b/python-pyfakefs.spec
index c8f976d..058cc12 100644
--- a/python-pyfakefs.spec
+++ b/python-pyfakefs.spec
@@ -89,8 +89,11 @@ export LC_ALL=C.UTF-8
 
 %if %{with tests}
 %{__python} -m pyfakefs.tests.all_tests
-PYTHONPATH=$(pwd)/build-2/lib PYTEST_PLUGINS=pyfakefs.pytest_plugin \
-py.test-2 build-2/lib/pyfakefs/tests/pytest_plugin_test.py
+
+PYTHONPATH=$(pwd) \
+PYTEST_DISABLE_PLUGIN_AUTOLOAD=1 \
+PYTEST_PLUGINS=pyfakefs.pytest_plugin \
+%{__python} -m pytest pyfakefs/tests/pytest_plugin_test.py
 %endif
 %endif
 
@@ -99,8 +102,10 @@ py.test-2 build-2/lib/pyfakefs/tests/pytest_plugin_test.py
 
 %if %{with tests}
 %{__python3} -m pyfakefs.tests.all_tests
-PYTHONPATH=$(pwd)/build-3/lib PYTEST_PLUGINS=pyfakefs.pytest_plugin \
-py.test-3 build-3/lib/pyfakefs/tests/pytest_plugin_test.py
+PYTHONPATH=$(pwd) \
+PYTEST_DISABLE_PLUGIN_AUTOLOAD=1 \
+PYTEST_PLUGINS=pyfakefs.pytest_plugin \
+%{__python3} -m pytest pyfakefs/tests/pytest_plugin_test.py
 %endif
 %endif
 
================================================================

---- gitweb:

http://git.pld-linux.org/gitweb.cgi/packages/python-pyfakefs.git/commitdiff/c45d0be8af1d42c06e14ef16fd74050e09105b95



More information about the pld-cvs-commit mailing list