Accepting request 826796 from devel:languages:python

OBS-URL: https://build.opensuse.org/request/show/826796
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/python-pyzmq?expand=0&rev=39
This commit is contained in:
Dominique Leuenberger 2020-08-25 10:36:20 +00:00 committed by Git OBS Bridge
commit ff83723a5b
2 changed files with 19 additions and 9 deletions

View File

@ -1,3 +1,8 @@
-------------------------------------------------------------------
Sat Aug 15 06:33:10 UTC 2020 - John Vandenberg <jayvdb@gmail.com>
- Re-activate test suite on x86_64, replacing nose with pytest
------------------------------------------------------------------- -------------------------------------------------------------------
Tue Aug 4 16:05:21 UTC 2020 - Dirk Mueller <dmueller@suse.com> Tue Aug 4 16:05:21 UTC 2020 - Dirk Mueller <dmueller@suse.com>

View File

@ -17,8 +17,12 @@
%{?!python_module:%define python_module() python-%{**} python3-%{**}} %{?!python_module:%define python_module() python-%{**} python3-%{**}}
# Disable tests, they are so slow that OBS thinks the build died. # Disable tests, they are very slow/halt on many arch
%bcond_with tests %ifarch x86_64
%bcond_without tests
%else
%bcond_with tests
%endif
Name: python-pyzmq Name: python-pyzmq
Version: 19.0.2 Version: 19.0.2
Release: 0 Release: 0
@ -34,11 +38,10 @@ BuildRequires: %{python_module cffi}
BuildRequires: %{python_module devel} BuildRequires: %{python_module devel}
BuildRequires: %{python_module gevent} BuildRequires: %{python_module gevent}
# Test requirements # Test requirements
BuildRequires: %{python_module nose}
BuildRequires: %{python_module numpy} BuildRequires: %{python_module numpy}
BuildRequires: %{python_module paramiko} BuildRequires: %{python_module paramiko}
BuildRequires: %{python_module pexpect} BuildRequires: %{python_module pexpect}
BuildRequires: %{python_module py} BuildRequires: %{python_module pytest}
BuildRequires: %{python_module setuptools} BuildRequires: %{python_module setuptools}
BuildRequires: %{python_module simplejson} BuildRequires: %{python_module simplejson}
BuildRequires: %{python_module tornado} BuildRequires: %{python_module tornado}
@ -77,6 +80,12 @@ Development libraries and headers needed to build software using %{name}.
# Fix non-executable script rpmlint warning: # Fix non-executable script rpmlint warning:
find examples zmq -name "*.py" -exec sed -i "s|#\!\/usr\/bin\/env python||" {} \; find examples zmq -name "*.py" -exec sed -i "s|#\!\/usr\/bin\/env python||" {} \;
# Remove non-deterministic authentication test
# This fails to connect randomly
rm -rf zmq/tests/test_auth.py
sed -i '/from zmq.tests.test_auth/d' zmq/tests/asyncio/_test_asyncio.py
sed -i 's/TestThreadAuthentication/object/' zmq/tests/asyncio/_test_asyncio.py
%patch1 %patch1
%build %build
@ -89,12 +98,8 @@ export CFLAGS="%{optflags}"
%if %{with tests} %if %{with tests}
%check %check
# Remove non-deterministic authentication test
# This fails to connect randomly
rm -rf zmq/tests/test_auth.py
%python_exec setup.py build_ext --inplace %python_exec setup.py build_ext --inplace
%python_exec setup.py test %pytest
%endif %endif
%files %{python_files} %files %{python_files}