- Switch to multibuild to avoid cycle bsc#1138666
OBS-URL: https://build.opensuse.org/package/show/devel:languages:python:pytest/python-py?expand=0&rev=14
This commit is contained in:
parent
7cc7715a9a
commit
044a6ef27a
3
_multibuild
Normal file
3
_multibuild
Normal file
@ -0,0 +1,3 @@
|
|||||||
|
<multibuild>
|
||||||
|
<package>test</package>
|
||||||
|
</multibuild>
|
@ -1,3 +1,8 @@
|
|||||||
|
-------------------------------------------------------------------
|
||||||
|
Wed Jun 19 10:08:47 UTC 2019 - Tomáš Chvátal <tchvatal@suse.com>
|
||||||
|
|
||||||
|
- Switch to multibuild to avoid cycle bsc#1138666
|
||||||
|
|
||||||
-------------------------------------------------------------------
|
-------------------------------------------------------------------
|
||||||
Wed Feb 27 13:48:08 UTC 2019 - Tomáš Chvátal <tchvatal@suse.com>
|
Wed Feb 27 13:48:08 UTC 2019 - Tomáš Chvátal <tchvatal@suse.com>
|
||||||
|
|
||||||
|
@ -18,7 +18,15 @@
|
|||||||
|
|
||||||
%define oldpython python
|
%define oldpython python
|
||||||
%{?!python_module:%define python_module() python-%{**} python3-%{**}}
|
%{?!python_module:%define python_module() python-%{**} python3-%{**}}
|
||||||
Name: python-py
|
%global flavor @BUILD_FLAVOR@%{nil}
|
||||||
|
%if "%{flavor}" == "test"
|
||||||
|
%define psuffix -test
|
||||||
|
%bcond_without test
|
||||||
|
%else
|
||||||
|
%define psuffix %{nil}
|
||||||
|
%bcond_with test
|
||||||
|
%endif
|
||||||
|
Name: python-py%{psuffix}
|
||||||
Version: 1.8.0
|
Version: 1.8.0
|
||||||
Release: 0
|
Release: 0
|
||||||
Summary: Library with cross-python path, ini-parsing, io, code, log facilities
|
Summary: Library with cross-python path, ini-parsing, io, code, log facilities
|
||||||
@ -26,13 +34,15 @@ License: MIT
|
|||||||
Group: Development/Languages/Python
|
Group: Development/Languages/Python
|
||||||
URL: https://github.com/pytest-dev/py
|
URL: https://github.com/pytest-dev/py
|
||||||
Source: https://files.pythonhosted.org/packages/source/p/py/py-%{version}.tar.gz
|
Source: https://files.pythonhosted.org/packages/source/p/py/py-%{version}.tar.gz
|
||||||
BuildRequires: %{python_module pytest}
|
|
||||||
BuildRequires: %{python_module setuptools_scm}
|
BuildRequires: %{python_module setuptools_scm}
|
||||||
BuildRequires: %{python_module setuptools}
|
BuildRequires: %{python_module setuptools}
|
||||||
BuildRequires: fdupes
|
BuildRequires: fdupes
|
||||||
BuildRequires: python-rpm-macros
|
BuildRequires: python-rpm-macros
|
||||||
Obsoletes: %{oldpython}-py-docs
|
Obsoletes: %{oldpython}-py-docs
|
||||||
BuildArch: noarch
|
BuildArch: noarch
|
||||||
|
%if %{with test}
|
||||||
|
BuildRequires: %{python_module pytest}
|
||||||
|
%endif
|
||||||
%python_subpackages
|
%python_subpackages
|
||||||
|
|
||||||
%description
|
%description
|
||||||
@ -57,19 +67,25 @@ rm -f testing/log/test_warning.py
|
|||||||
%python_build
|
%python_build
|
||||||
|
|
||||||
%install
|
%install
|
||||||
|
%if !%{with test}
|
||||||
%python_install
|
%python_install
|
||||||
%python_exec %fdupes %{buildroot}%{$python_sitelib}
|
%python_exec %fdupes %{buildroot}%{$python_sitelib}
|
||||||
|
%endif
|
||||||
|
|
||||||
%check
|
%check
|
||||||
|
%if %{with test}
|
||||||
export LANG=en_US.UTF-8
|
export LANG=en_US.UTF-8
|
||||||
# the passing is because upstream does not care about the results for now and
|
# the passing is because upstream does not care about the results for now and
|
||||||
# pinned pytest 3 in the repo (as this module is deprecated)
|
# pinned pytest 3 in the repo (as this module is deprecated)
|
||||||
# https://github.com/pytest-dev/py/issues/209
|
# https://github.com/pytest-dev/py/issues/209
|
||||||
%python_expand PYTHONPATH=%{buildroot}%{$python_sitelib} $python -m pytest || :
|
%pytest || :
|
||||||
|
%endif
|
||||||
|
|
||||||
|
%if !%{with test}
|
||||||
%files %{python_files}
|
%files %{python_files}
|
||||||
%doc README.rst
|
%doc README.rst
|
||||||
%license LICENSE
|
%license LICENSE
|
||||||
%{python_sitelib}/*
|
%{python_sitelib}/*
|
||||||
|
%endif
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
Loading…
Reference in New Issue
Block a user