14
0

Accepting request 744684 from devel:languages:python

- Update the add-rpmfail-pytest-markers.patch to not have
  pin on old pytest

OBS-URL: https://build.opensuse.org/request/show/744684
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/python-setuptools_scm?expand=0&rev=25
This commit is contained in:
2019-11-04 16:13:57 +00:00
committed by Git OBS Bridge
3 changed files with 12 additions and 7 deletions

View File

@@ -6,7 +6,7 @@ Index: setuptools_scm-3.3.3/testing/test_regressions.py
assert get_version(root=p.strpath, fallback_root=p.strpath) == "1.0" assert get_version(root=p.strpath, fallback_root=p.strpath) == "1.0"
+@pytest.mark.rpmfail_github_connect +@pytest.mark.xfail(reason="github connection")
@pytest.mark.issue(164) @pytest.mark.issue(164)
def test_pip_download(tmpdir, monkeypatch): def test_pip_download(tmpdir, monkeypatch):
monkeypatch.chdir(tmpdir) monkeypatch.chdir(tmpdir)
@@ -18,14 +18,14 @@ Index: setuptools_scm-3.3.3/testing/test_setuptools_support.py
) )
+@pytest.mark.rpmfail_github_connect +@pytest.mark.xfail(reason="github connection")
def test_old_setuptools_fails(get_setuptools_packagedir): def test_old_setuptools_fails(get_setuptools_packagedir):
packagedir = get_setuptools_packagedir("0.9.8") packagedir = get_setuptools_packagedir("0.9.8")
with pytest.raises(subprocess.CalledProcessError): with pytest.raises(subprocess.CalledProcessError):
check(packagedir, "0.9.8") check(packagedir, "0.9.8")
+@pytest.mark.rpmfail_github_connect +@pytest.mark.xfail(reason="github connection")
def test_old_setuptools_allows_with_warnings(get_setuptools_packagedir): def test_old_setuptools_allows_with_warnings(get_setuptools_packagedir):
packagedir = get_setuptools_packagedir("0.9.8") packagedir = get_setuptools_packagedir("0.9.8")
@@ -33,7 +33,7 @@ Index: setuptools_scm-3.3.3/testing/test_setuptools_support.py
check(packagedir, "0.9.8", PYTHONWARNINGS="once::Warning") check(packagedir, "0.9.8", PYTHONWARNINGS="once::Warning")
+@pytest.mark.rpmfail_github_connect +@pytest.mark.xfail(reason="github connection")
def test_distlib_setuptools_works(get_setuptools_packagedir): def test_distlib_setuptools_works(get_setuptools_packagedir):
packagedir = get_setuptools_packagedir("12.0.1") packagedir = get_setuptools_packagedir("12.0.1")
check(packagedir, "12.0.1") check(packagedir, "12.0.1")

View File

@@ -1,3 +1,9 @@
-------------------------------------------------------------------
Fri Nov 1 08:54:02 UTC 2019 - Tomáš Chvátal <tchvatal@suse.com>
- Update the add-rpmfail-pytest-markers.patch to not have
pin on old pytest
------------------------------------------------------------------- -------------------------------------------------------------------
Thu Jul 18 09:21:17 UTC 2019 - Tomáš Chvátal <tchvatal@suse.com> Thu Jul 18 09:21:17 UTC 2019 - Tomáš Chvátal <tchvatal@suse.com>

View File

@@ -30,7 +30,6 @@ Version: 3.3.3
Release: 0 Release: 0
Summary: Python setuptools handler for SCM tags Summary: Python setuptools handler for SCM tags
License: MIT License: MIT
Group: Development/Languages/Python
URL: https://github.com/pypa/setuptools_scm URL: https://github.com/pypa/setuptools_scm
Source: https://files.pythonhosted.org/packages/source/s/setuptools_scm/setuptools_scm-%{version}.tar.gz Source: https://files.pythonhosted.org/packages/source/s/setuptools_scm/setuptools_scm-%{version}.tar.gz
Patch0: add-rpmfail-pytest-markers.patch Patch0: add-rpmfail-pytest-markers.patch
@@ -42,7 +41,7 @@ BuildArch: noarch
%if %{with test} %if %{with test}
# Testing requirements # Testing requirements
BuildRequires: %{python_module pip} BuildRequires: %{python_module pip}
BuildRequires: %{python_module pytest < 4.0} BuildRequires: %{python_module pytest}
BuildRequires: %{python_module setuptools_scm = %{version}} BuildRequires: %{python_module setuptools_scm = %{version}}
BuildRequires: git-core BuildRequires: git-core
%endif %endif
@@ -70,7 +69,7 @@ in SCM metadata. It also handles file finders for the supperted SCMs.
%if %{with test} %if %{with test}
%check %check
%python_expand PYTHONPATH=%{$python_sitelib} py.test-%{$python_bin_suffix} -v -k 'not (rpmfail_github_connect or test_mercurial or hg)' %pytest -k 'not (test_mercurial or hg)'
%endif %endif
%if !%{with test} %if !%{with test}