From 869496c09bb157d04398eeeb0d53d0149bfda162 Mon Sep 17 00:00:00 2001 From: wang_yue111 <648774160@qq.com> Date: Fri, 11 Sep 2020 20:05:52 +0800 Subject: [PATCH] Move python2-pytest --- pytest.spec | 50 +++++++------------------------------------------- 1 file changed, 7 insertions(+), 43 deletions(-) diff --git a/pytest.spec b/pytest.spec index eb4b963..b4eae7c 100644 --- a/pytest.spec +++ b/pytest.spec @@ -6,7 +6,7 @@ Name: pytest Version: 3.6.4 -Release: 3 +Release: 4 Summary: A mature full-featured Python testing tool License: MIT URL: http://pytest.org @@ -24,23 +24,6 @@ applications and libraries. %description %{_description} -%package -n python2-%{name} -Summary: %{summary} -BuildRequires: python2-atomicwrites python2-attrs python2-devel python2-funcsigs -BuildRequires: python2-hypothesis python2-more-itertools >= 4.0.0 python2-pluggy -BuildRequires: python2-py >= %{pylib_version} python2-setuptools -BuildRequires: python2-setuptools_scm python2-six -Requires: python2-atomicwrites python2-attrs python2-funcsigs -Requires: python2-more-itertools >= 4.0.0 python2-pluggy python2-six -Requires: python2-py >= %{pylib_version} python2-setuptools - -%{?python_provide:%python_provide python2-%{name}} -Provides: %{name} = %{version}-%{release} -Obsoletes: %{name} < 2.8.7-3 - -%description -n python2-%{name} -%{_description} - %package -n python3-%{name} Summary: %{summary} BuildRequires: python3-atomicwrites python3-attrs python3-devel python3-hypothesis @@ -49,6 +32,7 @@ BuildRequires: python3-setuptools python3-setuptools_scm python3-six Requires: python3-atomicwrites python3-attrs python3-more-itertools Requires: python3-pluggy python3-py >= %{pylib_version} Requires: python3-setuptools python3-six +Obsoletes: %{name} = %{version}-%{release} %{?python_provide:%python_provide python3-%{name}} Obsoletes: platform-python-%{name} < %{version}-%{release} @@ -60,12 +44,10 @@ Obsoletes: platform-python-%{name} < %{version}-%{release} %package_help %endif - %prep %autosetup %build -%py2_build %py3_build %if 0%{?with_help} @@ -75,12 +57,6 @@ done %endif %install -%py2_install -for file in pytest py.test; do -mv $RPM_BUILD_ROOT%{_bindir}/${file} $RPM_BUILD_ROOT%{_bindir}/${file}-%{python2_version} -ln -snf ${file}-%{python2_version} $RPM_BUILD_ROOT%{_bindir}/${file}-2 -done - %py3_install for file in pytest py.test; do mv $RPM_BUILD_ROOT%{_bindir}/${file} $RPM_BUILD_ROOT%{_bindir}/${file}-%{python3_version} @@ -88,7 +64,7 @@ ln -snf ${file}-%{python3_version} $RPM_BUILD_ROOT%{_bindir}/${file}-3 done for file in pytest py.test; do -ln -snf ${file}-%{python2_version} $RPM_BUILD_ROOT%{_bindir}/${file} +ln -snf ${file}-%{python3_version} $RPM_BUILD_ROOT%{_bindir}/${file} done %if 0%{?with_help} @@ -101,31 +77,16 @@ find $RPM_BUILD_ROOT{%{python2_sitelib},%{python3_sitelib}} \ %check %if %{with tests} -PATH=$RPM_BUILD_ROOT%{_bindir}:${PATH} \ -PYTHONPATH=$RPM_BUILD_ROOT%{python2_sitelib} \ - $RPM_BUILD_ROOT%{_bindir}/pytest-%{python2_version} -r s testing \ - --timeout=30 - PATH=$RPM_BUILD_ROOT%{_bindir}:${PATH} \ PYTHONPATH=$RPM_BUILD_ROOT%{python3_sitelib} \ $RPM_BUILD_ROOT%{_bindir}/pytest-%{python3_version} -r s testing \ --timeout=30 %endif -%files -n python2-%{name} +%files -n python3-%{name} %license LICENSE %{_bindir}/pytest -%{_bindir}/pytest-2 -%{_bindir}/pytest-%{python2_version} %{_bindir}/py.test -%{_bindir}/py.test-2 -%{_bindir}/py.test-%{python2_version} -%{python2_sitelib}/pytest-*.egg-info/ -%{python2_sitelib}/_pytest/ -%{python2_sitelib}/pytest.py* - -%files -n python3-%{name} -%license LICENSE %{_bindir}/pytest-3 %{_bindir}/pytest-%{python3_version} %{_bindir}/py.test-3 @@ -141,6 +102,9 @@ PYTHONPATH=$RPM_BUILD_ROOT%{python3_sitelib} \ %endif %changelog +* Fri 11 Sep 2020 wangyue - 3.6.4-4 +- Remove python2-pytest + * Tue Dec 10 2019 mengxian - 3.6.4-2 - Package init -- Gitee