Remove python2

This commit is contained in:
jpzhang 2020-08-11 10:59:57 +08:00
parent 95f3c1a93e
commit 35e4694f77

View File

@ -1,6 +1,6 @@
Name: python-testscenarios Name: python-testscenarios
Version: 0.5.0 Version: 0.5.0
Release: 14 Release: 15
Summary: Provides clean dependency injection for python unittest style tests Summary: Provides clean dependency injection for python unittest style tests
License: ASL 2.0 and BSD License: ASL 2.0 and BSD
URL: https://launchpad.net/testscenarios URL: https://launchpad.net/testscenarios
@ -8,7 +8,6 @@ Source0: https://pypi.python.org/packages/source/t/testscenarios/testscen
BuildArch: noarch BuildArch: noarch
BuildRequires: python2-devel python2-fixtures python2-setuptools python2-pbr python2-testtools
BuildRequires: python3-devel python3-fixtures python3-setuptools python3-pbr python3-testtools BuildRequires: python3-devel python3-fixtures python3-setuptools python3-pbr python3-testtools
%description %description
@ -17,17 +16,6 @@ This can be used for interface testing (testing many implementations via a singl
or for classic dependency injection (provide tests with dependencies externally to or for classic dependency injection (provide tests with dependencies externally to
the test code itself, allowing easy testing in different situations). the test code itself, allowing easy testing in different situations).
%package -n python2-testscenarios
Summary: Provides clean dependency injection for python unittest style tests
Requires: python2-pbr python2-testtools
%{?python_provide:%python_provide python2-testscenarios}
%description -n python2-testscenarios
testscenarios provides clean dependency injection for python unittest style tests.
This can be used for interface testing (testing many implementations via a single test suite)
or for classic dependency injection (provide tests with dependencies externally to
the test code itself, allowing easy testing in different situations).
%package -n python3-testscenarios %package -n python3-testscenarios
Summary: Provides clean dependency injection for python unittest style tests Summary: Provides clean dependency injection for python unittest style tests
Requires: python3-pbr python3-testtools Requires: python3-pbr python3-testtools
@ -46,30 +34,22 @@ sed -i '/^buffer = 1$/d' setup.cfg
sed -i '/^catch = 1$/d' setup.cfg sed -i '/^catch = 1$/d' setup.cfg
%build %build
%py2_build
%py3_build %py3_build
%install %install
%py2_install
%py3_install %py3_install
%check %check
%{__python2} setup.py test
%{__python3} setup.py test %{__python3} setup.py test
%files -n python2-testscenarios
%doc GOALS HACKING NEWS README doc/
%license Apache-2.0 BSD
%{python2_sitelib}/testscenarios
%{python2_sitelib}/testscenarios-%{version}-py?.?.egg-info
%files -n python3-testscenarios %files -n python3-testscenarios
%license Apache-2.0 BSD %license Apache-2.0 BSD
%doc GOALS HACKING NEWS README doc/ %doc GOALS HACKING NEWS README doc/
%{python3_sitelib}/* %{python3_sitelib}/*
%changelog %changelog
* Mon Aug 10 2020 zhangjiapeng <zhangjiapeng9@huawei.com> - 0.5.0-15
- Remove python2
* Tue Nov 19 2019 openEuler Buildteam <buildteam@openeuler.org> - 0.5.0-14 * Tue Nov 19 2019 openEuler Buildteam <buildteam@openeuler.org> - 0.5.0-14
- Package init - Package init