Adapt tests for the pythonXY -> pythonX.Y renaming
See https://lists.fedoraproject.org/archives/list/python-devel@lists.fedoraproject.org/message/VIUS7WMQMDX6H2WEIH7TVTMBB6SUHY7E/
This commit is contained in:
parent
33358b9a65
commit
39315a6aa4
@ -17,19 +17,19 @@ rpm -qp --requires ${RPMDIR}/python3-zope-component-4.3.0-0.noarch.rpm | grep '^
|
||||
rpm -qp --requires ${RPMDIR}/python3-zope-component-4.3.0-0.noarch.rpm | grep '^python'$X_Y'dist(zope\.interface)'
|
||||
|
||||
|
||||
rpm -qp --provides ${RPMDIR}/python37-zope-component-4.3.0-0.noarch.rpm | grep '^python3dist(zope\.component)' && exit 1 || true
|
||||
rpm -qp --provides ${RPMDIR}/python37-zope-component-4.3.0-0.noarch.rpm | grep '^python3dist(zope-component)' && exit 1 || true
|
||||
rpm -qp --provides ${RPMDIR}/python37-zope-component-4.3.0-0.noarch.rpm | grep '^python3\.7dist(zope\.component)'
|
||||
rpm -qp --provides ${RPMDIR}/python37-zope-component-4.3.0-0.noarch.rpm | grep '^python3\.7dist(zope-component)'
|
||||
rpm -qp --provides ${RPMDIR}/python3.7-zope-component-4.3.0-0.noarch.rpm | grep '^python3dist(zope\.component)' && exit 1 || true
|
||||
rpm -qp --provides ${RPMDIR}/python3.7-zope-component-4.3.0-0.noarch.rpm | grep '^python3dist(zope-component)' && exit 1 || true
|
||||
rpm -qp --provides ${RPMDIR}/python3.7-zope-component-4.3.0-0.noarch.rpm | grep '^python3\.7dist(zope\.component)'
|
||||
rpm -qp --provides ${RPMDIR}/python3.7-zope-component-4.3.0-0.noarch.rpm | grep '^python3\.7dist(zope-component)'
|
||||
|
||||
rpm -qp --requires ${RPMDIR}/python37-zope-component-4.3.0-0.noarch.rpm | grep '^python3\.7dist(zope\.event)'
|
||||
rpm -qp --requires ${RPMDIR}/python37-zope-component-4.3.0-0.noarch.rpm | grep '^python3\.7dist(zope\.interface)'
|
||||
rpm -qp --requires ${RPMDIR}/python3.7-zope-component-4.3.0-0.noarch.rpm | grep '^python3\.7dist(zope\.event)'
|
||||
rpm -qp --requires ${RPMDIR}/python3.7-zope-component-4.3.0-0.noarch.rpm | grep '^python3\.7dist(zope\.interface)'
|
||||
|
||||
|
||||
rpm -qp --provides ${RPMDIR}/python310-zope-component-4.3.0-0.noarch.rpm | grep '^python3dist(zope\.component)' && exit 1 || true
|
||||
rpm -qp --provides ${RPMDIR}/python310-zope-component-4.3.0-0.noarch.rpm | grep '^python3dist(zope-component)' && exit 1 || true
|
||||
rpm -qp --provides ${RPMDIR}/python310-zope-component-4.3.0-0.noarch.rpm | grep '^python3\.10dist(zope\.component)'
|
||||
rpm -qp --provides ${RPMDIR}/python310-zope-component-4.3.0-0.noarch.rpm | grep '^python3\.10dist(zope-component)'
|
||||
rpm -qp --provides ${RPMDIR}/python3.10-zope-component-4.3.0-0.noarch.rpm | grep '^python3dist(zope\.component)' && exit 1 || true
|
||||
rpm -qp --provides ${RPMDIR}/python3.10-zope-component-4.3.0-0.noarch.rpm | grep '^python3dist(zope-component)' && exit 1 || true
|
||||
rpm -qp --provides ${RPMDIR}/python3.10-zope-component-4.3.0-0.noarch.rpm | grep '^python3\.10dist(zope\.component)'
|
||||
rpm -qp --provides ${RPMDIR}/python3.10-zope-component-4.3.0-0.noarch.rpm | grep '^python3\.10dist(zope-component)'
|
||||
|
||||
rpm -qp --requires ${RPMDIR}/python310-zope-component-4.3.0-0.noarch.rpm | grep '^python3\.10dist(zope\.event)'
|
||||
rpm -qp --requires ${RPMDIR}/python310-zope-component-4.3.0-0.noarch.rpm | grep '^python3\.10dist(zope\.interface)'
|
||||
rpm -qp --requires ${RPMDIR}/python3.10-zope-component-4.3.0-0.noarch.rpm | grep '^python3\.10dist(zope\.event)'
|
||||
rpm -qp --requires ${RPMDIR}/python3.10-zope-component-4.3.0-0.noarch.rpm | grep '^python3\.10dist(zope\.interface)'
|
||||
|
@ -19,14 +19,14 @@ Summary: ...
|
||||
%description -n python3-zope-component
|
||||
...
|
||||
|
||||
%package -n python37-zope-component
|
||||
%package -n python3.7-zope-component
|
||||
Summary: ...
|
||||
%description -n python37-zope-component
|
||||
%description -n python3.7-zope-component
|
||||
...
|
||||
|
||||
%package -n python310-zope-component
|
||||
%package -n python3.10-zope-component
|
||||
Summary: ...
|
||||
%description -n python310-zope-component
|
||||
%description -n python3.10-zope-component
|
||||
...
|
||||
|
||||
%prep
|
||||
@ -50,10 +50,10 @@ cp -a %{buildroot}%{python3_sitelib}/zope.component-%{version}-py%{python3_versi
|
||||
%license LICENSE.txt
|
||||
%{python3_sitelib}/*
|
||||
|
||||
%files -n python37-zope-component
|
||||
%files -n python3.7-zope-component
|
||||
%license LICENSE.txt
|
||||
/usr/lib/python3.7/site-packages/zope.component-%{version}-py3.7.egg-info/
|
||||
|
||||
%files -n python310-zope-component
|
||||
%files -n python3.10-zope-component
|
||||
%license LICENSE.txt
|
||||
/usr/lib/python3.10/site-packages/zope.component-%{version}-py3.10.egg-info/
|
||||
|
@ -1,18 +1,18 @@
|
||||
#!/usr/bin/bash -eux
|
||||
rpmbuild -ba pythonname.spec
|
||||
|
||||
XY=$(rpm --eval '%python3_version_nodots')
|
||||
X_Y=$(rpm --eval '%python3_version')
|
||||
RPMDIR=$(rpm --eval '%_topdir')/RPMS/noarch
|
||||
|
||||
echo "Provides for python${XY}-foo"
|
||||
rpm -qp --provides ${RPMDIR}/python${XY}-foo-0-0.noarch.rpm
|
||||
rpm -qp --provides ${RPMDIR}/python${XY}-foo-0-0.noarch.rpm | grep -q '^python-foo = 0-0$'
|
||||
rpm -qp --provides ${RPMDIR}/python${XY}-foo-0-0.noarch.rpm | grep -q '^python3-foo = 0-0$'
|
||||
echo "Provides for python${X_Y}-foo"
|
||||
rpm -qp --provides ${RPMDIR}/python${X_Y}-foo-0-0.noarch.rpm
|
||||
rpm -qp --provides ${RPMDIR}/python${X_Y}-foo-0-0.noarch.rpm | grep -q '^python-foo = 0-0$'
|
||||
rpm -qp --provides ${RPMDIR}/python${X_Y}-foo-0-0.noarch.rpm | grep -q '^python3-foo = 0-0$'
|
||||
|
||||
echo "Provides for python3-foo"
|
||||
rpm -qp --provides ${RPMDIR}/python3-foo-0-0.noarch.rpm
|
||||
rpm -qp --provides ${RPMDIR}/python3-foo-0-0.noarch.rpm | grep -q '^python-foo = 0-0$'
|
||||
rpm -qp --provides ${RPMDIR}/python3-foo-0-0.noarch.rpm | grep -q '^python'${XY}'-foo = 0-0$'
|
||||
rpm -qp --provides ${RPMDIR}/python3-foo-0-0.noarch.rpm | grep -q '^python'${X_Y}'-foo = 0-0$'
|
||||
|
||||
echo "Provides for python2-foo"
|
||||
rpm -qp --provides ${RPMDIR}/python2-foo-0-0.noarch.rpm
|
||||
@ -22,10 +22,10 @@ echo "Provides for python-foo"
|
||||
rpm -qp --provides ${RPMDIR}/python-foo-0-0.noarch.rpm
|
||||
rpm -qp --provides ${RPMDIR}/python-foo-0-0.noarch.rpm | grep -q '^python2-foo = 0-0$' && exit 1 || true
|
||||
|
||||
echo "Provides for python35-foo"
|
||||
rpm -qp --provides ${RPMDIR}/python35-foo-0-0.noarch.rpm
|
||||
rpm -qp --provides ${RPMDIR}/python35-foo-0-0.noarch.rpm | grep -q '^python-foo = 0-0$' && exit 1 || true
|
||||
rpm -qp --provides ${RPMDIR}/python35-foo-0-0.noarch.rpm | grep -q '^python3-foo = 0-0$' && exit 1 || true
|
||||
echo "Provides for python3.5-foo"
|
||||
rpm -qp --provides ${RPMDIR}/python3.5-foo-0-0.noarch.rpm
|
||||
rpm -qp --provides ${RPMDIR}/python3.5-foo-0-0.noarch.rpm | grep -q '^python-foo = 0-0$' && exit 1 || true
|
||||
rpm -qp --provides ${RPMDIR}/python3.5-foo-0-0.noarch.rpm | grep -q '^python3-foo = 0-0$' && exit 1 || true
|
||||
|
||||
echo "Provides for python3-python_provide"
|
||||
rpm -qp --provides ${RPMDIR}/python3-python_provide-0-0.noarch.rpm
|
||||
|
@ -38,19 +38,19 @@ Summary: ...
|
||||
/*
|
||||
|
||||
|
||||
%package -n python%{python3_version_nodots}-foo
|
||||
%package -n python%{python3_version}-foo
|
||||
Summary: ...
|
||||
%description -n python%{python3_version_nodots}-foo
|
||||
%description -n python%{python3_version}-foo
|
||||
...
|
||||
%files -n python%{python3_version_nodots}-foo
|
||||
%files -n python%{python3_version}-foo
|
||||
/*
|
||||
|
||||
|
||||
%package -n python35-foo
|
||||
%package -n python3.5-foo
|
||||
Summary: ...
|
||||
%description -n python35-foo
|
||||
%description -n python3.5-foo
|
||||
...
|
||||
%files -n python35-foo
|
||||
%files -n python3.5-foo
|
||||
/*
|
||||
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user