]> git.pld-linux.org Git - packages/python3-werkzeug.git/blobdiff - python-werkzeug.spec
- updated to 1.0.1
[packages/python3-werkzeug.git] / python-werkzeug.spec
index 6e4d2a59835e583f30af0d888e69992d8a5e4a7e..8e316ff1d3b66fa79fc32533958a38f50833097b 100644 (file)
@@ -1,7 +1,7 @@
 #
 # Conditional build:
 %bcond_without doc     # Sphinx documentation
-%bcond_with    tests   # test action
+%bcond_without tests   # test action
 %bcond_without python2 # CPython 2.x module
 %bcond_without python3 # CPython 3.x module
 
@@ -9,7 +9,7 @@
 Summary:       The Swiss Army knife of Python web development
 Summary(pl.UTF-8):     Scyzoryk szwajcarski programisty aplikacji WWW
 Name:          python-%{module}
-Version:       0.14.1
+Version:       1.0.1
 Release:       1
 License:       BSD
 Group:         Development/Languages/Python
@@ -18,43 +18,38 @@ Group:              Development/Languages/Python
 #Source0:      https://files.pythonhosted.org/packages/source/W/Werkzeug/Werkzeug-%{version}.tar.gz
 #Source0Download: https://github.com/pallets/werkzeug/releases
 Source0:       https://github.com/pallets/werkzeug/archive/%{version}/werkzeug-%{version}.tar.gz
-# Source0-md5: 9f8c9c008e0675ac96ba34f6db4375f9
-URL:           http://werkzeug.pocoo.org/
+# Source0-md5: 31e05a3d8e8e64e06b96c1c6a1a559ee
+URL:           https://werkzeug.palletsprojects.com/
 %if %{with python2}
-BuildRequires: python-devel >= 1:2.6
-BuildRequires: python-modules >= 1:2.6
+BuildRequires: python-devel >= 1:2.7
+BuildRequires: python-modules >= 1:2.7
 BuildRequires: python-setuptools
 %if %{with tests}
+BuildRequires: python-cryptography
 BuildRequires: python-greenlet
-BuildRequires: python-hypothesis
-# optional
-#BuildRequires:        python-memcached
 BuildRequires: python-pyOpenSSL
 BuildRequires: python-pytest
+BuildRequires: python-pytest-timeout
 # optional
 #BuildRequires:        python-pytest-xprocess
-# optional
-#BuildRequires:        python-redis
 BuildRequires: python-requests
+BuildRequires: python-requests-mock
 # optional
 #BuildRequires:        python-watchdog
 %endif
 %endif
 %if %{with python3}
-BuildRequires: python3-devel >= 1:3.3
-BuildRequires: python3-modules >= 1:3.3
+BuildRequires: python3-devel >= 1:3.5
+BuildRequires: python3-modules >= 1:3.5
 BuildRequires: python3-setuptools
 %if %{with tests}
+BuildRequires: python3-cryptography
 BuildRequires: python3-greenlet
-BuildRequires: python3-hypothesis
-# optional
-#BuildRequires:        python3-memcached
 BuildRequires: python3-pyOpenSSL
 BuildRequires: python3-pytest
+BuildRequires: python3-pytest-timeout
 # optional
 #BuildRequires:        python3-pytest-xprocess
-# optional
-#BuildRequires:        python3-redis
 BuildRequires: python3-requests
 # optional
 #BuildRequires:        python3-watchdog
@@ -63,9 +58,12 @@ BuildRequires:       python3-requests
 BuildRequires: rpm-pythonprov
 BuildRequires: rpmbuild(macros) >= 1.714
 %if %{with doc}
-BuildRequires: sphinx-pdg
+BuildRequires: python3-pallets-sphinx-themes
+BuildRequires: python3-sphinx_issues
+BuildRequires: python3-sphinxcontrib-log-cabinet
+BuildRequires: sphinx-pdg-3
 %endif
-Requires:      python-modules >= 1:2.6
+Requires:      python-modules >= 1:2.7
 BuildArch:     noarch
 BuildRoot:     %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
 
@@ -90,7 +88,7 @@ wiele dodatkowych modułów udostępnionych przez społeczność.
 Summary:       The Swiss Army knife of Python web development
 Summary(pl.UTF-8):     Scyzoryk szwajcarski programisty aplikacji WWW
 Group:         Libraries/Python
-Requires:      python3-modules >= 1:3.3
+Requires:      python3-modules >= 1:3.5
 
 %description -n python3-%{module}
 Werkzeug started as simple collection of various utilities for WSGI
@@ -125,16 +123,34 @@ Dokumentacja do pakietu Pythona Werkzeug.
 
 %build
 %if %{with python2}
-%py_build %{?with_tests:test}
+%py_build
+
+%if %{with tests}
+# requests_mock.contrib._pytest_plugin helps to workaround crash on cryptography deprecation warning(?)
+LC_ALL=C.UTF-8 \
+PYTEST_DISABLE_PLUGIN_AUTOLOAD=1 \
+PYTEST_PLUGINS=pytest_timeout,requests_mock.contrib._pytest_plugin \
+PYTHONPATH=$(pwd)/src \
+%{__python} -m pytest tests
+%endif
 %endif
 
 %if %{with python3}
-%py3_build %{?with_tests:test}
+%py3_build
+
+%if %{with tests}
+LC_ALL=C.UTF-8 \
+PYTEST_DISABLE_PLUGIN_AUTOLOAD=1 \
+PYTEST_PLUGINS=pytest_timeout \
+PYTHONPATH=$(pwd)/src \
+%{__python3} -m pytest tests
+%endif
 %endif
 
 %if %{with doc}
-PYTHONPATH=$(pwd) \
-%{__make} -C docs html
+PYTHONPATH=$(pwd)/src \
+%{__make} -C docs html \
+       SPHINXBUILD=sphinx-build-3
 %endif
 
 %install
@@ -164,7 +180,7 @@ rm -rf $RPM_BUILD_ROOT
 %if %{with python2}
 %files
 %defattr(644,root,root,755)
-%doc AUTHORS CHANGES.rst LICENSE README.rst
+%doc CHANGES.rst LICENSE.rst README.rst
 %{py_sitescriptdir}/werkzeug
 %{py_sitescriptdir}/Werkzeug-%{version}-py*.egg-info
 %{_examplesdir}/python-%{module}-%{version}
@@ -173,7 +189,7 @@ rm -rf $RPM_BUILD_ROOT
 %if %{with python3}
 %files -n python3-%{module}
 %defattr(644,root,root,755)
-%doc AUTHORS CHANGES.rst LICENSE README.rst
+%doc CHANGES.rst LICENSE.rst README.rst
 %{py3_sitescriptdir}/werkzeug
 %{py3_sitescriptdir}/Werkzeug-%{version}-py*.egg-info
 %{_examplesdir}/python3-%{module}-%{version}
@@ -182,5 +198,5 @@ rm -rf $RPM_BUILD_ROOT
 %if %{with doc}
 %files apidocs
 %defattr(644,root,root,755)
-%doc docs/_build/html/{_images,_static,contrib,deployment,*.html,*.js}
+%doc docs/_build/html/{_images,_static,deployment,middleware,*.html,*.js}
 %endif
This page took 0.107294 seconds and 4 git commands to generate.