diff --git a/_multibuild b/_multibuild new file mode 100644 index 0000000..fcc7b97 --- /dev/null +++ b/_multibuild @@ -0,0 +1,3 @@ + + test + diff --git a/python-setuptools_scm.changes b/python-setuptools_scm.changes index e1e2bc0..e7ea205 100644 --- a/python-setuptools_scm.changes +++ b/python-setuptools_scm.changes @@ -1,3 +1,8 @@ +------------------------------------------------------------------- +Tue Jul 31 10:03:17 UTC 2018 - tchvatal@suse.com + +- Add multibuild to run tests in -test package + ------------------------------------------------------------------- Tue Jul 31 09:12:41 UTC 2018 - tchvatal@suse.com diff --git a/python-setuptools_scm.spec b/python-setuptools_scm.spec index a3d67ae..37a82b1 100644 --- a/python-setuptools_scm.spec +++ b/python-setuptools_scm.spec @@ -17,7 +17,13 @@ %{?!python_module:%define python_module() python-%{**} python3-%{**}} +%global flavor @BUILD_FLAVOR@%{nil} +%if "%{flavor}" == "test" +%define test 1 +%bcond_without test +%else %bcond_with test +%endif Name: python-setuptools_scm Version: 3.0.5 Release: 0 @@ -37,6 +43,7 @@ BuildRequires: %{python_module pip} BuildRequires: %{python_module pytest} BuildRequires: git BuildRequires: mercurial +Requires: this-is-only-for-build-envs %endif %if 0%{?suse_version} || 0%{?fedora_version} >= 24 Recommends: git @@ -60,7 +67,7 @@ in scm metadata. It also handles file finders for the supperted scm's. %if %{with test} %check -%python_expand PYTHONPATH=%{buildroot}%{$python_sitelib} py.test-%{$python_bin_suffix} +%python_expand PYTHONPATH=%{buildroot}%{$python_sitelib} py.test-%{$python_bin_suffix} -v -k 'not (test_pip_download or test_old_setuptools_fails or test_old_setuptools_allows_with_warnings or test_distlib_setuptools_works)' %endif %files %{python_files}