!10 disable tests when bootstrapping

From: @tong_1001
Reviewed-by: @small_leek
Signed-off-by: @small_leek
This commit is contained in:
openeuler-ci-bot 2021-11-26 02:09:45 +00:00 committed by Gitee
commit 427687f926

View File

@ -1,7 +1,14 @@
%bcond_with bootstrap %bcond_without bootstrap
%if %{with bootstrap}
%bcond_with tests
%else
%bcond_without tests
%endif
Name: python-wheel Name: python-wheel
Version: 0.36.2 Version: 0.36.2
Release: 2 Release: 3
Epoch: 1 Epoch: 1
Summary: Built-package format for Python Summary: Built-package format for Python
License: MIT License: MIT
@ -18,7 +25,7 @@ compatible install in a way that is very close to the on-disk format.
%package -n python3-wheel %package -n python3-wheel
Summary: Built-package format for Python Summary: Built-package format for Python
BuildRequires: python3-devel python3-setuptools BuildRequires: python3-devel python3-setuptools
%if %{without bootstrap} %if %{with tests}
BuildRequires: python3-pytest python3-pyxdg BuildRequires: python3-pytest python3-pyxdg
%endif %endif
%{?python_provide:%python_provide python3-wheel} %{?python_provide:%python_provide python3-wheel}
@ -57,8 +64,9 @@ export PYTHONPATH=%{buildroot}%{python3_sitelib}
%py3_build_wheel %py3_build_wheel
install -d %{buildroot}%{_datadir}/python-wheels install -d %{buildroot}%{_datadir}/python-wheels
install -p dist/wheel-%{version}-py2.py3-none-any.whl -t %{buildroot}%{_datadir}/python-wheels install -p dist/wheel-%{version}-py2.py3-none-any.whl -t %{buildroot}%{_datadir}/python-wheels
%endif
%if %{with tests}
%check %check
rm setup.cfg rm setup.cfg
PYTHONPATH=%{buildroot}%{python3_sitelib} py.test-3 -v --ignore build PYTHONPATH=%{buildroot}%{python3_sitelib} py.test-3 -v --ignore build
@ -79,6 +87,9 @@ PYTHONPATH=%{buildroot}%{python3_sitelib} py.test-3 -v --ignore build
%endif %endif
%changelog %changelog
* Fri Nov 26 2021 shixuantong<shixuantong@huawei.com> - 0.36.2-3
- disable tests when bootstrapping
* Tue Jul 27 2021 shixuantong<shixuantong@huawei.com> - 0.36.2-2 * Tue Jul 27 2021 shixuantong<shixuantong@huawei.com> - 0.36.2-2
- remove useless BuildRequires - remove useless BuildRequires