From 7cc7715a9aa1501ab020db3f53127c4ff2d34375aad8ac8b8824fd2727868945 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tom=C3=A1=C5=A1=20Chv=C3=A1tal?= Date: Wed, 27 Feb 2019 13:50:12 +0000 Subject: [PATCH] - Update to 1.8.0: * add ``"importlib"`` pyimport mode for python3.5+, allowing unimportable test suites to contain identically named modules. * fix ``LocalPath.as_cwd()`` not calling ``os.chdir()`` with ``None``, when being invoked from a non-existing directory. OBS-URL: https://build.opensuse.org/package/show/devel:languages:python:pytest/python-py?expand=0&rev=12 --- py-1.7.0.tar.gz | 3 --- py-1.8.0.tar.gz | 3 +++ python-py.changes | 10 ++++++++++ python-py.spec | 4 +--- separators.patch | 51 ----------------------------------------------- 5 files changed, 14 insertions(+), 57 deletions(-) delete mode 100644 py-1.7.0.tar.gz create mode 100644 py-1.8.0.tar.gz delete mode 100644 separators.patch diff --git a/py-1.7.0.tar.gz b/py-1.7.0.tar.gz deleted file mode 100644 index 69cebb1..0000000 --- a/py-1.7.0.tar.gz +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:bf92637198836372b520efcba9e020c330123be8ce527e535d185ed4b6f45694 -size 202733 diff --git a/py-1.8.0.tar.gz b/py-1.8.0.tar.gz new file mode 100644 index 0000000..3c5bbbe --- /dev/null +++ b/py-1.8.0.tar.gz @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:dc639b046a6e2cff5bbe40194ad65936d6ba360b52b3c3fe1d08a82dd50b5e53 +size 205096 diff --git a/python-py.changes b/python-py.changes index dc305d3..794d7a4 100644 --- a/python-py.changes +++ b/python-py.changes @@ -1,3 +1,13 @@ +------------------------------------------------------------------- +Wed Feb 27 13:48:08 UTC 2019 - Tomáš Chvátal + +- Update to 1.8.0: + * add ``"importlib"`` pyimport mode for python3.5+, allowing unimportable test suites + to contain identically named modules. + * fix ``LocalPath.as_cwd()`` not calling ``os.chdir()`` with ``None``, when + being invoked from a non-existing directory. +- Drop merged patch separators.patch + ------------------------------------------------------------------- Fri Feb 15 11:19:55 UTC 2019 - Tomáš Chvátal diff --git a/python-py.spec b/python-py.spec index a60b2ae..c3e47cc 100644 --- a/python-py.spec +++ b/python-py.spec @@ -19,14 +19,13 @@ %define oldpython python %{?!python_module:%define python_module() python-%{**} python3-%{**}} Name: python-py -Version: 1.7.0 +Version: 1.8.0 Release: 0 Summary: Library with cross-python path, ini-parsing, io, code, log facilities License: MIT Group: Development/Languages/Python URL: https://github.com/pytest-dev/py Source: https://files.pythonhosted.org/packages/source/p/py/py-%{version}.tar.gz -Patch0: separators.patch BuildRequires: %{python_module pytest} BuildRequires: %{python_module setuptools_scm} BuildRequires: %{python_module setuptools} @@ -48,7 +47,6 @@ the following tools and modules: %prep %setup -q -n py-%{version} -%patch0 -p1 rm -rf py.egg-info rm -f tox.ini diff --git a/separators.patch b/separators.patch deleted file mode 100644 index 2ea363a..0000000 --- a/separators.patch +++ /dev/null @@ -1,51 +0,0 @@ -From a499409ee0f1234d45a80bf918cca18259fa9e1c Mon Sep 17 00:00:00 2001 -From: Anthony Sottile -Date: Thu, 22 Nov 2018 14:24:11 -0800 -Subject: [PATCH] Have at least one separator in sep() - -Before: - -``` - 1 failed, 1 passed, 1 skipped, 1 deselected, 1 xfailed, 1 xpassed, 1 error in 0.04 seconds -``` - -After: - -``` -= 1 failed, 1 passed, 1 skipped, 1 deselected, 1 xfailed, 1 xpassed, 1 error in 0.04 seconds = -``` ---- - py/_io/terminalwriter.py | 2 +- - testing/io_/test_terminalwriter.py | 6 ++++++ - 2 files changed, 7 insertions(+), 1 deletion(-) - -diff --git a/py/_io/terminalwriter.py b/py/_io/terminalwriter.py -index 817bf2d8..be559867 100644 ---- a/py/_io/terminalwriter.py -+++ b/py/_io/terminalwriter.py -@@ -227,7 +227,7 @@ def sep(self, sepchar, title=None, fullwidth=None, **kw): - # i.e. 2 + 2*len(sepchar)*N + len(title) <= fullwidth - # 2*len(sepchar)*N <= fullwidth - len(title) - 2 - # N <= (fullwidth - len(title) - 2) // (2*len(sepchar)) -- N = (fullwidth - len(title) - 2) // (2*len(sepchar)) -+ N = max((fullwidth - len(title) - 2) // (2*len(sepchar)), 1) - fill = sepchar * N - line = "%s %s %s" % (fill, title, fill) - else: -diff --git a/testing/io_/test_terminalwriter.py b/testing/io_/test_terminalwriter.py -index 64b07568..1eef7f7d 100644 ---- a/testing/io_/test_terminalwriter.py -+++ b/testing/io_/test_terminalwriter.py -@@ -165,6 +165,12 @@ def test_sep_with_title(self, tw): - assert len(l) == 1 - assert l[0] == "-" * 26 + " hello " + "-" * (27-win32) + "\n" - -+ def test_sep_longer_than_width(self, tw): -+ tw.sep('-', 'a' * 10, fullwidth=5) -+ line, = tw.getlines() -+ # even though the string is wider than the line, still have a separator -+ assert line == '- aaaaaaaaaa -\n' -+ - @py.test.mark.skipif("sys.platform == 'win32'") - def test__escaped(self, tw): - text2 = tw._escaped("hello", (31))