rdobuilder 45f8b7
# what it's called on pypi
rdobuilder 45f8b7
%global srcname testtools
rdobuilder 45f8b7
# what it's imported as
rdobuilder 45f8b7
%global libname %{srcname}
rdobuilder 45f8b7
# name of egg info directory
rdobuilder 45f8b7
%global eggname %{srcname}
rdobuilder 45f8b7
# package name fragment
rdobuilder 45f8b7
%global pkgname %{srcname}
rdobuilder 45f8b7
rdobuilder 45f8b7
%global common_description %{expand:
rdobuilder 45f8b7
testtools is a set of extensions to the Python standard library's unit testing
rdobuilder 45f8b7
framework.}
rdobuilder 45f8b7
rdobuilder 45f8b7
# To build this package in a new environment (i.e. a new EPEL branch), you'll
rdobuilder 45f8b7
# need to build in a particular order.
rdobuilder 45f8b7
#
rdobuilder 45f8b7
# 1. python-testtools with the tests disabled
rdobuilder 45f8b7
# 2. python-fixtures with the tests disabled
rdobuilder 45f8b7
# 3. python-testscenarios
rdobuilder 45f8b7
# 4. python-testtools and python-fixtures with tests enabled
rdobuilder 45f8b7
%bcond_without tests
rdobuilder 45f8b7
%bcond_without docs
rdobuilder 45f8b7
rdobuilder 45f8b7
Name:           python-%{pkgname}
rdobuilder 45f8b7
Version:        2.4.0
rdobuilder 45f8b7
Release:        10%{?dist}
rdobuilder 45f8b7
Summary:        Extensions to the Python unit testing framework
rdobuilder 45f8b7
rdobuilder 45f8b7
License:        MIT
rdobuilder 45f8b7
URL:            https://launchpad.net/testtools
rdobuilder 45f8b7
Source0:        %pypi_source
rdobuilder 45f8b7
Patch0:         testtools-2.4.0-remove_backports.patch
rdobuilder 45f8b7
# Reported as:
rdobuilder 45f8b7
# https://github.com/testing-cabal/testtools/pull/293
rdobuilder 45f8b7
Patch1:         testtools-2.4.0-fix_py39_test.patch
rdobuilder 45f8b7
rdobuilder 45f8b7
BuildArch:      noarch
rdobuilder 45f8b7
rdobuilder 45f8b7
%description %{common_description}
rdobuilder 45f8b7
rdobuilder 45f8b7
%package -n python3-%{pkgname}
rdobuilder 45f8b7
Summary:        %{summary}
rdobuilder 45f8b7
BuildRequires: make
rdobuilder 45f8b7
BuildRequires:  python3-devel
rdobuilder 45f8b7
BuildRequires:  %{py3_dist setuptools extras python-mimeparse pbr}
rdobuilder 45f8b7
%if %{with tests}
rdobuilder 45f8b7
BuildRequires:  %{py3_dist testscenarios}
rdobuilder 45f8b7
%endif
rdobuilder 45f8b7
%{?python_provide:%python_provide python3-%{pkgname}}
rdobuilder 45f8b7
rdobuilder 45f8b7
%description -n python3-%{pkgname} %{common_description}
rdobuilder 45f8b7
rdobuilder 45f8b7
%if %{with docs}
rdobuilder 45f8b7
%package        doc
rdobuilder 45f8b7
BuildRequires:  %{py3_dist sphinx}
rdobuilder 45f8b7
Summary:        Documentation for %{name}
rdobuilder 45f8b7
rdobuilder 45f8b7
# https://fedoraproject.org/wiki/Packaging:No_Bundled_Libraries#Packages_granted_temporary_exceptions
rdobuilder 45f8b7
Provides:       bundled(jquery)
rdobuilder 45f8b7
rdobuilder 45f8b7
%description doc
rdobuilder 45f8b7
This package contains HTML documentation for %{name}.
rdobuilder 45f8b7
%endif
rdobuilder 45f8b7
rdobuilder 45f8b7
rdobuilder 45f8b7
%prep
rdobuilder 45f8b7
%autosetup -p 1 -n %{srcname}-%{version}
rdobuilder 45f8b7
rm -rf %{eggname}.egg-info
rdobuilder 45f8b7
rm testtools/_compat2x.py
rdobuilder 45f8b7
rdobuilder 45f8b7
rdobuilder 45f8b7
%build
rdobuilder 45f8b7
%py3_build
rdobuilder 45f8b7
rdobuilder 45f8b7
%if %{with docs}
rdobuilder 45f8b7
PYTHONPATH=$PWD make -C doc html
rdobuilder 45f8b7
%endif
rdobuilder 45f8b7
rdobuilder 45f8b7
rdobuilder 45f8b7
%install
rdobuilder 45f8b7
%py3_install
rdobuilder 45f8b7
rdobuilder 45f8b7
rdobuilder 45f8b7
%if %{with tests}
rdobuilder 45f8b7
%check
rdobuilder 45f8b7
make PYTHON=%{__python3} check
rdobuilder 45f8b7
%endif
rdobuilder 45f8b7
rdobuilder 45f8b7
%files -n python3-%{pkgname}
rdobuilder 45f8b7
%doc NEWS README.rst
rdobuilder 45f8b7
%license LICENSE
rdobuilder 45f8b7
%{python3_sitelib}/%{libname}
rdobuilder 45f8b7
%{python3_sitelib}/%{eggname}-%{version}-py%{python3_version}.egg-info
rdobuilder 45f8b7
rdobuilder 45f8b7
%if %{with docs}
rdobuilder 45f8b7
%files doc
rdobuilder 45f8b7
%doc doc/_build/html/*
rdobuilder 45f8b7
%endif
rdobuilder 45f8b7
rdobuilder 45f8b7
rdobuilder 45f8b7
%changelog
rdobuilder 45f8b7
* Fri Jun 04 2021 Python Maint <python-maint@redhat.com> - 2.4.0-10
rdobuilder 45f8b7
- Rebuilt for Python 3.10
rdobuilder 45f8b7
rdobuilder 45f8b7
* Wed Jun 02 2021 Python Maint <python-maint@redhat.com> - 2.4.0-9
rdobuilder 45f8b7
- Bootstrap for Python 3.10
rdobuilder 45f8b7
rdobuilder 45f8b7
* Wed Jan 27 2021 Fedora Release Engineering <releng@fedoraproject.org> - 2.4.0-8
rdobuilder 45f8b7
- Rebuilt for https://fedoraproject.org/wiki/Fedora_34_Mass_Rebuild
rdobuilder 45f8b7
rdobuilder 45f8b7
* Wed Jul 29 2020 Fedora Release Engineering <releng@fedoraproject.org> - 2.4.0-7
rdobuilder 45f8b7
- Rebuilt for https://fedoraproject.org/wiki/Fedora_33_Mass_Rebuild
rdobuilder 45f8b7
rdobuilder 45f8b7
* Fri May 22 2020 Miro Hrončok <mhroncok@redhat.com> - 2.4.0-6
rdobuilder 45f8b7
- Rebuilt for Python 3.9
rdobuilder 45f8b7
rdobuilder 45f8b7
* Fri May 22 2020 Miro Hrončok <mhroncok@redhat.com> - 2.4.0-5
rdobuilder 45f8b7
- Bootstrap for Python 3.9
rdobuilder 45f8b7
rdobuilder 45f8b7
* Sat May 16 2020 Michel Alexandre Salim <salimma@fedoraproject.org> - 2.4.0-4
rdobuilder 45f8b7
- Fix syntax error test on Python 3.9
rdobuilder 45f8b7
rdobuilder 45f8b7
* Fri Apr 24 2020 Carl George <carl@george.computer> - 2.4.0-3
rdobuilder 45f8b7
- Enable tests
rdobuilder 45f8b7
rdobuilder 45f8b7
* Fri Apr 24 2020 Carl George <carl@george.computer> - 2.4.0-2
rdobuilder 45f8b7
- Disable tests for EPEL8 bootstrap
rdobuilder 45f8b7
rdobuilder 45f8b7
* Fri Apr  3 2020 Michel Alexandre Salim <salimma@fedoraproject.org> - 2.4.0-1
rdobuilder 45f8b7
- Update to 2.4.0
rdobuilder 45f8b7
rdobuilder 45f8b7
* Thu Feb 20 2020 Avram Lubkin <aviso@rockhopper.net> - 2.3.0-18
rdobuilder 45f8b7
- Patch to remove unittest2 and traceback2 from source
rdobuilder 45f8b7
rdobuilder 45f8b7
* Thu Jan 30 2020 Fedora Release Engineering <releng@fedoraproject.org> - 2.3.0-17
rdobuilder 45f8b7
- Rebuilt for https://fedoraproject.org/wiki/Fedora_32_Mass_Rebuild
rdobuilder 45f8b7
rdobuilder 45f8b7
* Thu Jan 09 2020 Avram Lubkin <aviso@rockhopper.net> - 2.3.0-16
rdobuilder 45f8b7
- Remove unittest2 dependency
rdobuilder 45f8b7
- Remove traceback2 dependency
rdobuilder 45f8b7
rdobuilder 45f8b7
* Thu Oct 03 2019 Miro Hrončok <mhroncok@redhat.com> - 2.3.0-15
rdobuilder 45f8b7
- Subpackage python2-testtools has been removed
rdobuilder 45f8b7
  See https://fedoraproject.org/wiki/Changes/Mass_Python_2_Package_Removal
rdobuilder 45f8b7
rdobuilder 45f8b7
* Thu Sep 26 2019 Miro Hrončok <mhroncok@redhat.com> - 2.3.0-14
rdobuilder 45f8b7
- Reduce the build dependencies by not running tests on Python 2
rdobuilder 45f8b7
rdobuilder 45f8b7
* Thu Aug 15 2019 Miro Hrončok <mhroncok@redhat.com> - 2.3.0-13
rdobuilder 45f8b7
- Rebuilt for Python 3.8
rdobuilder 45f8b7
rdobuilder 45f8b7
* Thu Aug 15 2019 Miro Hrončok <mhroncok@redhat.com> - 2.3.0-12
rdobuilder 45f8b7
- Bootstrap for Python 3.8
rdobuilder 45f8b7
rdobuilder 45f8b7
* Fri Jul 26 2019 Fedora Release Engineering <releng@fedoraproject.org> - 2.3.0-11
rdobuilder 45f8b7
- Rebuilt for https://fedoraproject.org/wiki/Fedora_31_Mass_Rebuild
rdobuilder 45f8b7
rdobuilder 45f8b7
* Sat Jun 15 2019 Michel Alexandre Salim <salimma@fedoraproject.org> - 2.3.0-11
rdobuilder 45f8b7
- Update project URL
rdobuilder 45f8b7
rdobuilder 45f8b7
* Sat Feb 02 2019 Fedora Release Engineering <releng@fedoraproject.org> - 2.3.0-10
rdobuilder 45f8b7
- Rebuilt for https://fedoraproject.org/wiki/Fedora_30_Mass_Rebuild
rdobuilder 45f8b7
rdobuilder 45f8b7
* Sat Jul 14 2018 Fedora Release Engineering <releng@fedoraproject.org> - 2.3.0-9
rdobuilder 45f8b7
- Rebuilt for https://fedoraproject.org/wiki/Fedora_29_Mass_Rebuild
rdobuilder 45f8b7
rdobuilder 45f8b7
* Mon Jun 18 2018 Miro Hrončok <mhroncok@redhat.com> - 2.3.0-8
rdobuilder 45f8b7
- Rebuilt for Python 3.7
rdobuilder 45f8b7
rdobuilder 45f8b7
* Tue Jun 05 2018 Miro Hrončok <mhroncok@redhat.com> - 2.3.0-7
rdobuilder 45f8b7
- Backport upstream patch for Python 3.7 support (#1577621)
rdobuilder 45f8b7
- Use python2 explicitly
rdobuilder 45f8b7
rdobuilder 45f8b7
* Fri Mar 09 2018 Iryna Shcherbina <ishcherb@redhat.com> - 2.3.0-6
rdobuilder 45f8b7
- Update Python 2 dependency declarations to new packaging standards
rdobuilder 45f8b7
  (See https://fedoraproject.org/wiki/FinalizingFedoraSwitchtoPython3)
rdobuilder 45f8b7
rdobuilder 45f8b7
* Fri Feb 09 2018 Fedora Release Engineering <releng@fedoraproject.org> - 2.3.0-5
rdobuilder 45f8b7
- Rebuilt for https://fedoraproject.org/wiki/Fedora_28_Mass_Rebuild
rdobuilder 45f8b7
rdobuilder 45f8b7
* Fri Sep 29 2017 Troy Dawson <tdawson@redhat.com> - 2.3.0-4
rdobuilder 45f8b7
- Cleanup spec file conditionals
rdobuilder 45f8b7
rdobuilder 45f8b7
* Sat Aug 19 2017 Zbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl> - 2.3.0-3
rdobuilder 45f8b7
- Python 2 binary package renamed to python2-testtools
rdobuilder 45f8b7
  See https://fedoraproject.org/wiki/FinalizingFedoraSwitchtoPython3
rdobuilder 45f8b7
rdobuilder 45f8b7
* Thu Jul 27 2017 Fedora Release Engineering <releng@fedoraproject.org> - 2.3.0-2
rdobuilder 45f8b7
- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Mass_Rebuild
rdobuilder 45f8b7
rdobuilder 45f8b7
* Wed Jun 14 2017 Haïkel Guémar <hguemar@fedoraproject.org> - 2.3.0-1
rdobuilder 45f8b7
- Upstream 2.3.0
rdobuilder 45f8b7
- Refresh spec
rdobuilder 45f8b7
rdobuilder 45f8b7
* Sat Feb 11 2017 Fedora Release Engineering <releng@fedoraproject.org> - 1.8.0-8
rdobuilder 45f8b7
- Rebuilt for https://fedoraproject.org/wiki/Fedora_26_Mass_Rebuild
rdobuilder 45f8b7
rdobuilder 45f8b7
* Fri Dec 09 2016 Charalampos Stratakis <cstratak@redhat.com> - 1.8.0-7
rdobuilder 45f8b7
- Rebuild for Python 3.6
rdobuilder 45f8b7
rdobuilder 45f8b7
* Tue Jul 19 2016 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.8.0-6
rdobuilder 45f8b7
- https://fedoraproject.org/wiki/Changes/Automatic_Provides_for_Python_RPM_Packages
rdobuilder 45f8b7
rdobuilder 45f8b7
* Fri Jun  3 2016 Michel Alexandre Salim <salimma@fedoraproject.org> - 1.8.0-5
rdobuilder 45f8b7
- Add runtime dependency on traceback2 (bz#1251568)
rdobuilder 45f8b7
- Bump required version of unittest2 (bz#1304326)
rdobuilder 45f8b7
rdobuilder 45f8b7
* Thu Feb 04 2016 Fedora Release Engineering <releng@fedoraproject.org> - 1.8.0-4
rdobuilder 45f8b7
- Rebuilt for https://fedoraproject.org/wiki/Fedora_24_Mass_Rebuild
rdobuilder 45f8b7
rdobuilder 45f8b7
* Tue Nov 10 2015 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.8.0-3
rdobuilder 45f8b7
- Rebuilt for https://fedoraproject.org/wiki/Changes/python3.5
rdobuilder 45f8b7
rdobuilder 45f8b7
* Tue Jul 28 2015 Michel Alexandre Salim <salimma@fedoraproject.org> - 1.8.0-2
rdobuilder 45f8b7
- Provide python2-testtools per updated guidelines
rdobuilder 45f8b7
rdobuilder 45f8b7
* Tue Jul 28 2015 Michel Alexandre Salim <salimma@fedoraproject.org> - 1.8.0-1
rdobuilder 45f8b7
- Update to 1.8.0
rdobuilder 45f8b7
rdobuilder 45f8b7
* Thu Jun 18 2015 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.5.0-2
rdobuilder 45f8b7
- Rebuilt for https://fedoraproject.org/wiki/Fedora_23_Mass_Rebuild
rdobuilder 45f8b7
rdobuilder 45f8b7
* Thu Nov 27 2014 Michel Alexandre Salim <salimma@fedoraproject.org> - 1.5.0-1
rdobuilder 45f8b7
- Update to 1.5.0
rdobuilder 45f8b7
rdobuilder 45f8b7
* Fri Sep 19 2014 Jerry James <loganjerry@gmail.com> - 1.1.0-1
rdobuilder 45f8b7
- Update to 1.1.0 (bz 1132881)
rdobuilder 45f8b7
- Fix license handling
rdobuilder 45f8b7
- Note bundling exception for jquery in -doc
rdobuilder 45f8b7
rdobuilder 45f8b7
* Sat Jun 07 2014 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.9.35-4
rdobuilder 45f8b7
- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_Mass_Rebuild
rdobuilder 45f8b7
rdobuilder 45f8b7
* Wed May 14 2014 Bohuslav Kabrda <bkabrda@redhat.com> - 0.9.35-3
rdobuilder 45f8b7
- Rebuilt for https://fedoraproject.org/wiki/Changes/Python_3.4
rdobuilder 45f8b7
rdobuilder 45f8b7
* Fri Feb 28 2014 Matthias Runge <mrunge@redhat.com> - 0.9.35-2
rdobuilder 45f8b7
- re-enable building the python3-subpackage
rdobuilder 45f8b7
rdobuilder 45f8b7
* Mon Feb  3 2014 Michel Salim <salimma@fedoraproject.org> - 0.9.35-1
rdobuilder 45f8b7
- Update to 0.9.35
rdobuilder 45f8b7
rdobuilder 45f8b7
* Sun Aug 04 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.9.32-3
rdobuilder 45f8b7
- Rebuilt for https://fedoraproject.org/wiki/Fedora_20_Mass_Rebuild
rdobuilder 45f8b7
rdobuilder 45f8b7
* Thu Jul  4 2013 Michel Salim <salimma@fedoraproject.org> - 0.9.32-2
rdobuilder 45f8b7
- Add new runtime dep on -extras to Python3 variant as well
rdobuilder 45f8b7
rdobuilder 45f8b7
* Thu Jul  4 2013 Michel Salim <salimma@fedoraproject.org> - 0.9.32-1
rdobuilder 45f8b7
- Update to 0.9.32
rdobuilder 45f8b7
- Switch to using split-off extras package
rdobuilder 45f8b7
rdobuilder 45f8b7
* Sat May 18 2013 Pádraig Brady <pbrady@redhat.com> - 0.9.30-1
rdobuilder 45f8b7
- Update to 0.9.30
rdobuilder 45f8b7
rdobuilder 45f8b7
* Thu Feb 07 2013 Pádraig Brady <pbrady@redhat.com> - 0.9.29-1
rdobuilder 45f8b7
- Update to 0.9.29
rdobuilder 45f8b7
rdobuilder 45f8b7
* Sat Oct 27 2012 Michel Alexandre Salim <michel@sojourner> - 0.9.21-1
rdobuilder 45f8b7
- Update to 0.9.21
rdobuilder 45f8b7
rdobuilder 45f8b7
* Sat Oct 20 2012 Michel Salim <salimma@fedoraproject.org> - 0.9.19-1
rdobuilder 45f8b7
- Update to 0.9.19
rdobuilder 45f8b7
- On Fedora, also build for Python 3.x
rdobuilder 45f8b7
rdobuilder 45f8b7
* Wed Sep  5 2012 Michel Salim <salimma@fedoraproject.org> - 0.9.16-1
rdobuilder 45f8b7
- Update to 0.9.16
rdobuilder 45f8b7
- Remove deprecated sections
rdobuilder 45f8b7
rdobuilder 45f8b7
* Sat Jul 21 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.9.15-2
rdobuilder 45f8b7
- Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild
rdobuilder 45f8b7
rdobuilder 45f8b7
* Fri May 11 2012 Michel Salim <salimma@fedoraproject.org> - 0.9.15-1
rdobuilder 45f8b7
- Update to 0.9.15
rdobuilder 45f8b7
rdobuilder 45f8b7
* Thu Apr  5 2012 Michel Salim <salimma@fedoraproject.org> - 0.9.14-1
rdobuilder 45f8b7
- Update to 0.9.14
rdobuilder 45f8b7
- Enable unit tests
rdobuilder 45f8b7
rdobuilder 45f8b7
* Tue Feb  7 2012 Michel Salim <salimma@fedoraproject.org> - 0.9.13-1
rdobuilder 45f8b7
- Update to 0.9.13
rdobuilder 45f8b7
rdobuilder 45f8b7
* Tue Jan 31 2012 Michel Salim <salimma@fedoraproject.org> - 0.9.12-1
rdobuilder 45f8b7
- Update to 0.9.12
rdobuilder 45f8b7
rdobuilder 45f8b7
* Sat Jan 14 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.9.11-2
rdobuilder 45f8b7
- Rebuilt for https://fedoraproject.org/wiki/Fedora_17_Mass_Rebuild
rdobuilder 45f8b7
rdobuilder 45f8b7
* Fri Jul 15 2011 Michel Salim <salimma@fedoraproject.org> - 0.9.11-1
rdobuilder 45f8b7
- Update to 0.9.11
rdobuilder 45f8b7
- Enable documentation generation
rdobuilder 45f8b7
rdobuilder 45f8b7
* Thu Apr  7 2011 Michel Salim <salimma@fedoraproject.org> - 0.9.8-2
rdobuilder 45f8b7
- Add definitions needed by older RPM versions
rdobuilder 45f8b7
rdobuilder 45f8b7
* Thu Apr  7 2011 Michel Salim <salimma@fedoraproject.org> - 0.9.8-1
rdobuilder 45f8b7
- Initial package