|
|
0282c82 |
%if 0%{?fedora}
|
|
|
0282c82 |
%global with_python3 1
|
|
|
0282c82 |
%endif
|
|
|
0282c82 |
|
|
Michel Alexandre Salim |
cd750e1 |
Name: python-testtools
|
|
|
c37d78e |
Version: 0.9.32
|
|
|
748cd6d |
Release: 2%{?dist}
|
|
Michel Alexandre Salim |
cd750e1 |
Summary: Extensions to the Python unit testing framework
|
|
Michel Alexandre Salim |
cd750e1 |
|
|
|
2303662 |
%if 0%{?rhel}
|
|
Michel Alexandre Salim |
cd750e1 |
Group: Development/Tools
|
|
|
2303662 |
%endif
|
|
Michel Alexandre Salim |
cd750e1 |
License: MIT
|
|
Michel Alexandre Salim |
cd750e1 |
URL: https://launchpad.net/testtools
|
|
|
ae2856e |
Source0: http://pypi.python.org/packages/source/t/testtools/testtools-%{version}.tar.gz
|
|
|
c37d78e |
Patch0: testtools-0.9.30-py3.patch
|
|
Michel Alexandre Salim |
cd750e1 |
|
|
Michel Alexandre Salim |
cd750e1 |
BuildArch: noarch
|
|
Michel Alexandre Salim |
cd750e1 |
BuildRequires: python2-devel
|
|
|
c37d78e |
BuildRequires: python-extras
|
|
|
b1d5f0c |
BuildRequires: python-mimeparse >= 0.1.4
|
|
|
50efbbf |
BuildRequires: python-setuptools
|
|
|
0282c82 |
%if 0%{?with_python3}
|
|
|
0282c82 |
BuildRequires: python3-devel
|
|
|
c37d78e |
BuildRequires: python3-extras
|
|
|
b1d5f0c |
BuildRequires: python3-mimeparse
|
|
|
50efbbf |
BuildRequires: python3-setuptools
|
|
|
0282c82 |
%endif
|
|
|
ae2856e |
BuildRequires: python-sphinx
|
|
Michel Alexandre Salim |
cd750e1 |
|
|
|
c37d78e |
Requires: python-extras
|
|
|
b1d5f0c |
Requires: python-mimeparse
|
|
|
b1d5f0c |
|
|
Michel Alexandre Salim |
cd750e1 |
%description
|
|
Michel Alexandre Salim |
cd750e1 |
testtools is a set of extensions to the Python standard library's unit testing
|
|
Michel Alexandre Salim |
cd750e1 |
framework.
|
|
Michel Alexandre Salim |
cd750e1 |
|
|
|
0282c82 |
|
|
|
0282c82 |
%if 0%{?with_python3}
|
|
|
0282c82 |
%package -n python3-testtools
|
|
|
0282c82 |
Summary: Extensions to the Python unit testing framework
|
|
|
0282c82 |
|
|
|
748cd6d |
Requires: python3-extras
|
|
|
b1d5f0c |
Requires: python3-mimeparse
|
|
|
b1d5f0c |
|
|
|
0282c82 |
%description -n python3-testtools
|
|
|
0282c82 |
testtools is a set of extensions to the Python standard library's unit testing
|
|
|
0282c82 |
framework.
|
|
|
0282c82 |
|
|
|
0282c82 |
%endif # with_python3
|
|
|
0282c82 |
|
|
|
0282c82 |
|
|
|
ae2856e |
%package doc
|
|
|
ae2856e |
Summary: Documentation for %{name}
|
|
|
ae2856e |
Group: Documentation
|
|
|
ae2856e |
|
|
|
ae2856e |
Requires: %{name} = %{version}-%{release}
|
|
|
ae2856e |
|
|
|
ae2856e |
%description doc
|
|
|
50efbbf |
This package contains HTML documentation for %{name}.
|
|
|
ae2856e |
|
|
Michel Alexandre Salim |
cd750e1 |
|
|
Michel Alexandre Salim |
cd750e1 |
%prep
|
|
Michel Alexandre Salim |
cd750e1 |
%setup -q -n testtools-%{version}
|
|
Michel Alexandre Salim |
cd750e1 |
|
|
|
0282c82 |
%if 0%{?with_python3}
|
|
|
0282c82 |
rm -rf %{py3dir}
|
|
|
0282c82 |
cp -a . %{py3dir}
|
|
|
0282c82 |
|
|
|
0282c82 |
# make the Python 3 build load the Python 3.x compatibility library directly
|
|
|
0282c82 |
pushd %{py3dir}
|
|
|
c37d78e |
%patch0 -p1 -b.py3
|
|
|
0282c82 |
popd
|
|
|
0282c82 |
|
|
|
0282c82 |
find %{py3dir} -name '*.py' | xargs sed -i '1s|^#!python|#!%{__python3}|'
|
|
|
0282c82 |
rm %{py3dir}/testtools/_compat2x.py
|
|
|
0282c82 |
rm testtools/_compat3x.py
|
|
|
0282c82 |
%endif # with_python3
|
|
|
0282c82 |
|
|
Michel Alexandre Salim |
cd750e1 |
|
|
Michel Alexandre Salim |
cd750e1 |
%build
|
|
Michel Alexandre Salim |
cd750e1 |
%{__python} setup.py build
|
|
|
0282c82 |
|
|
|
0282c82 |
%if 0%{?with_python3}
|
|
|
0282c82 |
pushd %{py3dir}
|
|
|
0282c82 |
%{__python3} setup.py build
|
|
|
0282c82 |
popd
|
|
|
0282c82 |
%endif # with_python3
|
|
|
0282c82 |
|
|
|
ae2856e |
make -C doc html
|
|
Michel Alexandre Salim |
cd750e1 |
|
|
Michel Alexandre Salim |
cd750e1 |
|
|
Michel Alexandre Salim |
cd750e1 |
%install
|
|
|
0282c82 |
# do python3 install first in case python-testtools ever install scripts in
|
|
|
0282c82 |
# _bindir -- the one installed last should be Python 2.x's as that's the
|
|
|
0282c82 |
# current default
|
|
|
0282c82 |
%if 0%{?with_python3}
|
|
|
0282c82 |
pushd %{py3dir}
|
|
|
0282c82 |
%{__python3} setup.py install -O1 --skip-build --root $RPM_BUILD_ROOT
|
|
|
0282c82 |
popd
|
|
|
0282c82 |
%endif # with_python3
|
|
|
0282c82 |
|
|
Michel Alexandre Salim |
cd750e1 |
%{__python} setup.py install -O1 --skip-build --root $RPM_BUILD_ROOT
|
|
Michel Alexandre Salim |
cd750e1 |
|
|
Michel Alexandre Salim |
cd750e1 |
|
|
|
0282c82 |
|
|
|
0707c41 |
%check
|
|
|
50efbbf |
make PYTHON=%{__python} check
|
|
|
0707c41 |
|
|
|
0282c82 |
%if 0%{?with_python3}
|
|
|
0282c82 |
pushd %{py3dir}
|
|
|
50efbbf |
make PYTHON=%{__python3} check
|
|
|
0282c82 |
popd
|
|
|
0282c82 |
%endif # with_python3
|
|
|
0707c41 |
|
|
Michel Alexandre Salim |
cd750e1 |
|
|
Michel Alexandre Salim |
cd750e1 |
%files
|
|
Michel Alexandre Salim |
cd750e1 |
%defattr(-,root,root,-)
|
|
|
50efbbf |
%doc LICENSE NEWS README.rst
|
|
Michel Alexandre Salim |
cd750e1 |
%{python_sitelib}/*
|
|
Michel Alexandre Salim |
cd750e1 |
|
|
|
0282c82 |
%if 0%{?with_python3}
|
|
|
0282c82 |
%files -n python3-testtools
|
|
|
50efbbf |
%doc LICENSE NEWS README.rst
|
|
|
0282c82 |
%{python3_sitelib}/*
|
|
|
0282c82 |
%endif
|
|
|
0282c82 |
|
|
|
ae2856e |
%files doc
|
|
|
ae2856e |
%defattr(-,root,root,-)
|
|
|
ae2856e |
%doc doc/_build/html/*
|
|
|
ae2856e |
|
|
Michel Alexandre Salim |
cd750e1 |
|
|
Michel Alexandre Salim |
cd750e1 |
%changelog
|
|
|
748cd6d |
* Thu Jul 4 2013 Michel Salim <salimma@fedoraproject.org> - 0.9.32-2
|
|
|
748cd6d |
- Add new runtime dep on -extras to Python3 variant as well
|
|
|
748cd6d |
|
|
|
c37d78e |
* Thu Jul 4 2013 Michel Salim <salimma@fedoraproject.org> - 0.9.32-1
|
|
|
c37d78e |
- Update to 0.9.32
|
|
|
c37d78e |
- Switch to using split-off extras package
|
|
|
c37d78e |
|
|
|
b1d5f0c |
* Sat May 18 2013 Pádraig Brady <pbrady@redhat.com> - 0.9.30-1
|
|
|
b1d5f0c |
- Update to 0.9.30
|
|
|
b1d5f0c |
|
|
|
50efbbf |
* Thu Feb 07 2013 Pádraig Brady <pbrady@redhat.com> - 0.9.29-1
|
|
|
50efbbf |
- Update to 0.9.29
|
|
|
50efbbf |
|
|
|
73bf407 |
* Sat Oct 27 2012 Michel Alexandre Salim <michel@sojourner> - 0.9.21-1
|
|
|
73bf407 |
- Update to 0.9.21
|
|
|
73bf407 |
|
|
|
0282c82 |
* Sat Oct 20 2012 Michel Salim <salimma@fedoraproject.org> - 0.9.19-1
|
|
|
0282c82 |
- Update to 0.9.19
|
|
|
0282c82 |
- On Fedora, also build for Python 3.x
|
|
|
0282c82 |
|
|
|
470e9bd |
* Wed Sep 5 2012 Michel Salim <salimma@fedoraproject.org> - 0.9.16-1
|
|
|
470e9bd |
- Update to 0.9.16
|
|
|
470e9bd |
- Remove deprecated sections
|
|
|
470e9bd |
|
|
|
cf636f6 |
* Sat Jul 21 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.9.15-2
|
|
|
cf636f6 |
- Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild
|
|
|
cf636f6 |
|
|
|
2303662 |
* Fri May 11 2012 Michel Salim <salimma@fedoraproject.org> - 0.9.15-1
|
|
|
2303662 |
- Update to 0.9.15
|
|
|
2303662 |
|
|
|
0707c41 |
* Thu Apr 5 2012 Michel Salim <salimma@fedoraproject.org> - 0.9.14-1
|
|
|
0707c41 |
- Update to 0.9.14
|
|
|
0707c41 |
- Enable unit tests
|
|
|
0707c41 |
|
|
|
da38fcb |
* Tue Feb 7 2012 Michel Salim <salimma@fedoraproject.org> - 0.9.13-1
|
|
|
da38fcb |
- Update to 0.9.13
|
|
|
da38fcb |
|
|
|
009fc17 |
* Tue Jan 31 2012 Michel Salim <salimma@fedoraproject.org> - 0.9.12-1
|
|
|
009fc17 |
- Update to 0.9.12
|
|
|
009fc17 |
|
|
|
36b8fb4 |
* Sat Jan 14 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.9.11-2
|
|
|
36b8fb4 |
- Rebuilt for https://fedoraproject.org/wiki/Fedora_17_Mass_Rebuild
|
|
|
36b8fb4 |
|
|
|
ae2856e |
* Fri Jul 15 2011 Michel Salim <salimma@fedoraproject.org> - 0.9.11-1
|
|
|
ae2856e |
- Update to 0.9.11
|
|
|
ae2856e |
- Enable documentation generation
|
|
|
ae2856e |
|
|
Michel Alexandre Salim |
cd750e1 |
* Thu Apr 7 2011 Michel Salim <salimma@fedoraproject.org> - 0.9.8-2
|
|
Michel Alexandre Salim |
cd750e1 |
- Add definitions needed by older RPM versions
|
|
Michel Alexandre Salim |
cd750e1 |
|
|
Michel Alexandre Salim |
cd750e1 |
* Thu Apr 7 2011 Michel Salim <salimma@fedoraproject.org> - 0.9.8-1
|
|
Michel Alexandre Salim |
cd750e1 |
- Initial package
|