3 %bcond_without tests # do not perform "make test" (use for extras/testtools pair bootstrap)
4 %bcond_without python2 # CPython 2.x module
5 %bcond_without python3 # CPython 3.x module
7 Summary: Useful extra bits for Python - things that should be in the standard library
8 Summary(pl.UTF-8): Przydatne dodatki do Pythona, które powinny być w bibliotece standardowej
13 Group: Libraries/Python
14 #Source0Download: https://pypi.org/simple/extras/
15 Source0: https://files.pythonhosted.org/packages/source/e/extras/extras-%{version}.tar.gz
16 # Source0-md5: 3a63ad60cf8f0186c9e3a02f55ec5b14
17 URL: https://github.com/testing-cabal/extras
18 BuildRequires: rpm-pythonprov
19 BuildRequires: rpmbuild(macros) >= 1.714
21 BuildRequires: python-modules >= 1:2.6
22 BuildRequires: python-setuptools
24 BuildRequires: python-testtools
28 BuildRequires: python3-modules >= 1:3.2
29 BuildRequires: python3-setuptools
31 BuildRequires: python3-testtools
34 Requires: python-modules >= 1:2.6
36 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
39 extras is a set of extensions to the Python standard library,
40 originally written to make the code within testtools cleaner, but now
41 split out for general use outside of a testing context.
43 %description -l pl.UTF-8
44 extras to zbiór rozszerzeń biblioteki standardowej Pythona, pierwotnie
45 napisany, aby uczynić kod biblioteki testtools czytelniejszym, ale
46 później wydzielony do ogólnego użytku, nie tylko w kontekście testów.
48 %package -n python3-extras
49 Summary: Useful extra bits for Python - things that should be in the standard library
50 Summary(pl.UTF-8): Przydatne dodatki do Pythona, które powinny być w bibliotece standardowej
51 Group: Libraries/Python
52 Requires: python3-modules >= 1:3.2
54 %description -n python3-extras
55 extras is a set of extensions to the Python standard library,
56 originally written to make the code within testtools cleaner, but now
57 split out for general use outside of a testing context.
59 %description -n python3-extras -l pl.UTF-8
60 extras to zbiór rozszerzeń biblioteki standardowej Pythona, pierwotnie
61 napisany, aby uczynić kod biblioteki testtools czytelniejszym, ale
62 później wydzielony do ogólnego użytku, nie tylko w kontekście testów.
65 %setup -q -n extras-%{version}
72 %{__python} -m unittest discover -s extras.tests
80 %{__python3} -m unittest discover -s extras.tests
85 rm -rf $RPM_BUILD_ROOT
91 %{__rm} -r $RPM_BUILD_ROOT%{py_sitescriptdir}/extras/tests
97 %{__rm} -r $RPM_BUILD_ROOT%{py3_sitescriptdir}/extras/tests
101 rm -rf $RPM_BUILD_ROOT
105 %defattr(644,root,root,755)
106 %doc LICENSE NEWS README.rst
107 %{py_sitescriptdir}/extras
108 %{py_sitescriptdir}/extras-%{version}-py*.egg-info
112 %files -n python3-extras
113 %defattr(644,root,root,755)
114 %doc LICENSE NEWS README.rst
115 %{py3_sitescriptdir}/extras
116 %{py3_sitescriptdir}/extras-%{version}-py*.egg-info