]> git.pld-linux.org Git - packages/python3-filelock.git/blobdiff - python-filelock.spec
use use pytest for running tests
[packages/python3-filelock.git] / python-filelock.spec
index 29600d137fefb70faa10fdd0a26d70e5d140c10c..3424646bb59f655548a4be87d8c9f44edccdb014 100644 (file)
@@ -7,23 +7,29 @@
 Summary:       A platform independent file lock
 Summary(pl.UTF-8):     Niezależne od platformy blokady plikowe
 Name:          python-filelock
-Version:       3.0.12
-Release:       2
+Version:       3.2.1
+Release:       1
 License:       Public Domain
 Group:         Libraries/Python
 #Source0Download: https://pypi.org/simple/filelock/
 Source0:       https://files.pythonhosted.org/packages/source/f/filelock/filelock-%{version}.tar.gz
-# Source0-md5: c1fe6d9a7433a7ca6ce4f36e273317d1
+# Source0-md5: 92fea9fb4ebf39d746c77ec6c4c87be0
 URL:           https://pypi.org/project/filelock/
 BuildRequires: rpm-pythonprov
 BuildRequires: rpmbuild(macros) >= 1.714
 %if %{with python2}
 BuildRequires: python-modules >= 1:2.7
 BuildRequires: python-setuptools
+%if %{with tests}
+BuildRequires: python-pytest
+%endif
 %endif
 %if %{with python3}
 BuildRequires: python3-modules >= 1:3.4
 BuildRequires: python3-setuptools
+%if %{with tests}
+BuildRequires: python3-pytest
+%endif
 %endif
 Requires:      python-modules >= 1:2.7
 BuildArch:     noarch
@@ -63,7 +69,8 @@ komunikacji międzyprocesowej.
 %py_build
 
 %if %{with tests}
-%{__python} test.py
+PYTHONPATH=$(pwd)/src \
+%{__python} -m pytest tests
 %endif
 %endif
 
@@ -71,7 +78,8 @@ komunikacji międzyprocesowej.
 %py3_build
 
 %if %{with tests}
-%{__python3} test.py
+PYTHONPATH=$(pwd)/src \
+%{__python3} -m pytest tests
 %endif
 %endif
 
@@ -95,7 +103,7 @@ rm -rf $RPM_BUILD_ROOT
 %files
 %defattr(644,root,root,755)
 %doc LICENSE README.md
-%{py_sitescriptdir}/filelock.py[co]
+%{py_sitescriptdir}/filelock
 %{py_sitescriptdir}/filelock-%{version}-py*.egg-info
 %endif
 
@@ -103,7 +111,6 @@ rm -rf $RPM_BUILD_ROOT
 %files -n python3-filelock
 %defattr(644,root,root,755)
 %doc LICENSE README.md
-%{py3_sitescriptdir}/filelock.py
-%{py3_sitescriptdir}/__pycache__/filelock.cpython-*.py[co]
+%{py3_sitescriptdir}/filelock
 %{py3_sitescriptdir}/filelock-%{version}-py*.egg-info
 %endif
This page took 0.102054 seconds and 4 git commands to generate.