Hello community,

here is the log from the commit of package python-stestr for openSUSE:Factory 
checked in at 2019-11-22 10:25:59
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/python-stestr (Old)
 and      /work/SRC/openSUSE:Factory/.python-stestr.new.26869 (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "python-stestr"

Fri Nov 22 10:25:59 2019 rev:13 rq:749499 version:2.5.1

Changes:
--------
--- /work/SRC/openSUSE:Factory/python-stestr/python-stestr.changes      
2019-11-04 17:12:52.836676122 +0100
+++ /work/SRC/openSUSE:Factory/.python-stestr.new.26869/python-stestr.changes   
2019-11-22 10:26:00.561263197 +0100
@@ -1,0 +2,7 @@
+Sun Nov 17 17:19:01 UTC 2019 - Hans-Peter Jansen <[email protected]>
+
+- Create multibuild for testing in order to cope with a circular
+  dependency with python-cliff
+- Clean up spec file
+
+-------------------------------------------------------------------

New:
----
  _multibuild

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Other differences:
------------------
++++++ python-stestr.spec ++++++
--- /var/tmp/diff_new_pack.w1ybY8/_old  2019-11-22 10:26:01.741262850 +0100
+++ /var/tmp/diff_new_pack.w1ybY8/_new  2019-11-22 10:26:01.777262838 +0100
@@ -1,7 +1,7 @@
 #
 # spec file for package python-stestr
 #
-# Copyright (c) 2019 SUSE LINUX GmbH, Nuernberg, Germany.
+# Copyright (c) 2019 SUSE LLC
 #
 # All modifications and additions to the file contributed by third parties
 # remain the property of their copyright owners, unless otherwise agreed
@@ -17,7 +17,15 @@
 
 
 %{?!python_module:%define python_module() python-%{**} python3-%{**}}
-Name:           python-stestr
+%global flavor @BUILD_FLAVOR@%{nil}
+%if "%{flavor}" == "test"
+%define psuffix -%{flavor}
+%bcond_without test
+%else
+%define psuffix %{nil}
+%bcond_with test
+%endif
+Name:           python-stestr%{psuffix}
 Version:        2.5.1
 Release:        0
 Summary:        A test runner runner similar to testrepository
@@ -25,21 +33,8 @@
 Group:          Development/Languages/Python
 URL:            https://github.com/mtreinish/stestr
 Source:         
https://files.pythonhosted.org/packages/source/s/stestr/stestr-%{version}.tar.gz
-BuildRequires:  %{python_module PyYAML >= 3.10.0}
-BuildRequires:  %{python_module SQLAlchemy}
-BuildRequires:  %{python_module cliff >= 2.8.0}
-BuildRequires:  %{python_module coverage >= 4.0}
-BuildRequires:  %{python_module ddt >= 1.0.1}
-BuildRequires:  %{python_module fixtures >= 3.0.0}
-BuildRequires:  %{python_module future}
-BuildRequires:  %{python_module mock >= 2.0}
 BuildRequires:  %{python_module pbr >= 2.0.0}
-BuildRequires:  %{python_module pytest}
-BuildRequires:  %{python_module python-subunit >= 1.3.0}
 BuildRequires:  %{python_module setuptools}
-BuildRequires:  %{python_module six >= 1.10.0}
-BuildRequires:  %{python_module testtools >= 2.2.0}
-BuildRequires:  %{python_module voluptuous >= 0.8.9}
 BuildRequires:  fdupes
 BuildRequires:  python-rpm-macros
 BuildRequires:  python3-dbm
@@ -52,16 +47,32 @@
 Requires:       python-six >= 1.10.0
 Requires:       python-testtools >= 2.2.0
 Requires:       python-voluptuous >= 0.8.9
+Requires(post): update-alternatives
+Requires(postun): update-alternatives
+BuildArch:      noarch
+%if %{with test}
+BuildRequires:  %{python_module PyYAML >= 3.10.0}
+BuildRequires:  %{python_module SQLAlchemy}
+BuildRequires:  %{python_module cliff >= 2.8.0}
+BuildRequires:  %{python_module coverage >= 4.0}
+BuildRequires:  %{python_module ddt >= 1.0.1}
+BuildRequires:  %{python_module fixtures >= 3.0.0}
+BuildRequires:  %{python_module future}
+BuildRequires:  %{python_module mock >= 2.0}
+BuildRequires:  %{python_module pytest}
+BuildRequires:  %{python_module python-subunit >= 1.3.0}
+BuildRequires:  %{python_module six >= 1.10.0}
+BuildRequires:  %{python_module stestr >= %{version}}
+BuildRequires:  %{python_module testtools >= 2.2.0}
+BuildRequires:  %{python_module voluptuous >= 0.8.9}
+%endif
 %ifpython3
 Requires:       python-dbm
 %endif
-Requires(post): update-alternatives
-Requires(postun): update-alternatives
 %if !0%{?_no_weakdeps}
 Recommends:     python-SQLAlchemy
 Recommends:     python-subunit2sql >= 1.8.0
 %endif
-BuildArch:      noarch
 %python_subpackages
 
 %description
@@ -77,6 +88,13 @@
 # do not test sql
 rm stestr/tests/repository/test_sql.py
 
+%if %{with test}
+%check
+export LC_ALL="en_US.UTF8"
+%pytest stestr/tests -k 'not test_empty_with_pretty_out'
+%endif
+
+%if ! %{with test}
 %build
 export LC_ALL="en_US.UTF8"
 %python_build
@@ -87,21 +105,6 @@
 %python_clone -a %{buildroot}%{_bindir}/stestr
 %python_expand %fdupes %{buildroot}%{$python_sitelib}
 
-%check
-export LC_ALL="en_US.UTF8"
-# test_empty_with_pretty_out - edge case not triggered in OBS
-%{python_expand mkdir build/bin
-for filepath in %{buildroot}/%{_bindir}/stestr*-%{$python_bin_suffix}; do
-  filename=$(basename $filepath)
-  unsuffixed=${filename/-%{$python_bin_suffix}/}
-  cp $filepath build/bin/$unsuffixed
-done
-export PATH="$(pwd)/build/bin:$PATH"
-export PYTHONPATH=%{buildroot}%{$python_sitelib}
-py.test-%{$python_bin_suffix} -v stestr/tests -k 'not 
test_empty_with_pretty_out'
-rm -r build/bin
-}
-
 %post
 %python_install_alternative stestr
 
@@ -113,5 +116,6 @@
 %doc ChangeLog README.rst
 %python_alternative %{_bindir}/stestr
 %{python_sitelib}/*
+%endif
 
 %changelog

++++++ _multibuild ++++++
<multibuild>
  <package>test</package>
</multibuild>

Reply via email to