forked from pool/python-pytest-sugar
- Update to 0.9.3:
* Fix incompatibility with pytest 5.4.0 (thanks @GuillaumeFavelier) - Drop patch pytest4.patch OBS-URL: https://build.opensuse.org/package/show/devel:languages:python:pytest/python-pytest-sugar?expand=0&rev=8
This commit is contained in:
committed by
Git OBS Bridge
parent
88d9cd1820
commit
e86c665800
@@ -1,3 +0,0 @@
|
|||||||
version https://git-lfs.github.com/spec/v1
|
|
||||||
oid sha256:fcd87a74b2bce5386d244b49ad60549bfbc4602527797fac167da147983f58ab
|
|
||||||
size 12677
|
|
||||||
3
pytest-sugar-0.9.3.tar.gz
Normal file
3
pytest-sugar-0.9.3.tar.gz
Normal file
@@ -0,0 +1,3 @@
|
|||||||
|
version https://git-lfs.github.com/spec/v1
|
||||||
|
oid sha256:1630b5b7ea3624919b73fde37cffb87965c5087a4afab8a43074ff44e0d810c4
|
||||||
|
size 12649
|
||||||
@@ -1,31 +0,0 @@
|
|||||||
From 681461f488260eb8c4c9db4530b9572af058477e Mon Sep 17 00:00:00 2001
|
|
||||||
From: Daniel Hahler <git@thequod.de>
|
|
||||||
Date: Mon, 11 Feb 2019 22:08:41 +0100
|
|
||||||
Subject: [PATCH] Fix print_failure for pytest 4.2
|
|
||||||
|
|
||||||
Fixes https://github.com/Frozenball/pytest-sugar/issues/170.
|
|
||||||
---
|
|
||||||
pytest_sugar.py | 8 +++++---
|
|
||||||
1 file changed, 5 insertions(+), 3 deletions(-)
|
|
||||||
|
|
||||||
diff --git a/pytest_sugar.py b/pytest_sugar.py
|
|
||||||
index 6dbe70f..c479dab 100644
|
|
||||||
--- a/pytest_sugar.py
|
|
||||||
+++ b/pytest_sugar.py
|
|
||||||
@@ -616,11 +616,13 @@ def print_failure(self, report):
|
|
||||||
self.write_line(line)
|
|
||||||
else:
|
|
||||||
msg = self._getfailureheadline(report)
|
|
||||||
- if not hasattr(report, 'when'):
|
|
||||||
+ # "when" was unset before pytest 4.2 for collection errors.
|
|
||||||
+ when = getattr(report, "when", "collect")
|
|
||||||
+ if when == "collect":
|
|
||||||
msg = "ERROR collecting " + msg
|
|
||||||
- elif report.when == "setup":
|
|
||||||
+ elif when == "setup":
|
|
||||||
msg = "ERROR at setup of " + msg
|
|
||||||
- elif report.when == "teardown":
|
|
||||||
+ elif when == "teardown":
|
|
||||||
msg = "ERROR at teardown of " + msg
|
|
||||||
self.write_line('')
|
|
||||||
self.write_sep("―", msg)
|
|
||||||
@@ -1,3 +1,10 @@
|
|||||||
|
-------------------------------------------------------------------
|
||||||
|
Mon Apr 27 09:30:57 UTC 2020 - Tomáš Chvátal <tchvatal@suse.com>
|
||||||
|
|
||||||
|
- Update to 0.9.3:
|
||||||
|
* Fix incompatibility with pytest 5.4.0 (thanks @GuillaumeFavelier)
|
||||||
|
- Drop patch pytest4.patch
|
||||||
|
|
||||||
-------------------------------------------------------------------
|
-------------------------------------------------------------------
|
||||||
Wed Jul 24 07:09:44 UTC 2019 - Tomáš Chvátal <tchvatal@suse.com>
|
Wed Jul 24 07:09:44 UTC 2019 - Tomáš Chvátal <tchvatal@suse.com>
|
||||||
|
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
#
|
#
|
||||||
# spec file for package python-pytest-sugar
|
# spec file for package python-pytest-sugar
|
||||||
#
|
#
|
||||||
# Copyright (c) 2019 SUSE LINUX GmbH, Nuernberg, Germany.
|
# Copyright (c) 2020 SUSE LLC
|
||||||
#
|
#
|
||||||
# All modifications and additions to the file contributed by third parties
|
# All modifications and additions to the file contributed by third parties
|
||||||
# remain the property of their copyright owners, unless otherwise agreed
|
# remain the property of their copyright owners, unless otherwise agreed
|
||||||
@@ -18,20 +18,18 @@
|
|||||||
|
|
||||||
%{?!python_module:%define python_module() python-%{**} python3-%{**}}
|
%{?!python_module:%define python_module() python-%{**} python3-%{**}}
|
||||||
Name: python-pytest-sugar
|
Name: python-pytest-sugar
|
||||||
Version: 0.9.2
|
Version: 0.9.3
|
||||||
Release: 0
|
Release: 0
|
||||||
Summary: Pretty printer for pytest progress
|
Summary: Pretty printer for pytest progress
|
||||||
License: BSD-3-Clause
|
License: BSD-3-Clause
|
||||||
Group: Development/Languages/Python
|
|
||||||
URL: https://github.com/Frozenball/pytest-sugar
|
URL: https://github.com/Frozenball/pytest-sugar
|
||||||
Source: https://files.pythonhosted.org/packages/source/p/pytest-sugar/pytest-sugar-%{version}.tar.gz
|
Source: https://files.pythonhosted.org/packages/source/p/pytest-sugar/pytest-sugar-%{version}.tar.gz
|
||||||
Patch0: pytest4.patch
|
|
||||||
BuildRequires: %{python_module pytest}
|
BuildRequires: %{python_module pytest}
|
||||||
BuildRequires: %{python_module setuptools}
|
BuildRequires: %{python_module setuptools}
|
||||||
BuildRequires: %{python_module termcolor}
|
BuildRequires: %{python_module termcolor}
|
||||||
BuildRequires: fdupes
|
BuildRequires: fdupes
|
||||||
BuildRequires: python-rpm-macros
|
BuildRequires: python-rpm-macros
|
||||||
Requires: python-pytest < 5.0
|
Requires: python-pytest
|
||||||
Requires: python-termcolor
|
Requires: python-termcolor
|
||||||
BuildArch: noarch
|
BuildArch: noarch
|
||||||
%python_subpackages
|
%python_subpackages
|
||||||
@@ -41,7 +39,6 @@ pytest-sugar is a plugin for py.test that shows failures and errors instantly an
|
|||||||
|
|
||||||
%prep
|
%prep
|
||||||
%setup -q -n pytest-sugar-%{version}
|
%setup -q -n pytest-sugar-%{version}
|
||||||
%patch0 -p1
|
|
||||||
|
|
||||||
%build
|
%build
|
||||||
%python_build
|
%python_build
|
||||||
|
|||||||
Reference in New Issue
Block a user