- Update to 0.7.1:

- calling `setUp` and `tearDown` in parameterized classesq
- Add skip_Documentation_tests.patch to skip over test cases,
  failing with Python 3.8. gh#wolever/parameterized#84

OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-parameterized?expand=0&rev=14
This commit is contained in:
Matej Cepl 2019-12-05 15:15:14 +00:00 committed by Git OBS Bridge
parent 1fd3449c50
commit 7d01845bb4
5 changed files with 41 additions and 9 deletions

View File

@ -1,3 +0,0 @@
version https://git-lfs.github.com/spec/v1
oid sha256:d8c8837fb677ed2d5a93b9e2308ce0da3aeb58cf513120d501e0b7af14da78d5
size 20751

View File

@ -0,0 +1,3 @@
version https://git-lfs.github.com/spec/v1
oid sha256:6a94dbea30c6abde99fd4c2f2042c1bf7f980e48908bf92ead62394f93cf57ed
size 22365

View File

@ -1,3 +1,11 @@
-------------------------------------------------------------------
Thu Dec 5 15:52:40 CET 2019 - Matej Cepl <mcepl@suse.com>
- Update to 0.7.1:
- calling `setUp` and `tearDown` in parameterized classesq
- Add skip_Documentation_tests.patch to skip over test cases,
failing with Python 3.8. gh#wolever/parameterized#84
-------------------------------------------------------------------
Tue Nov 5 09:31:02 UTC 2019 - Ondřej Súkup <mimi.vx@gmail.com>

View File

@ -1,7 +1,7 @@
#
# spec file for package python-parameterized
#
# 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
@ -18,24 +18,26 @@
%{?!python_module:%define python_module() python-%{**} python3-%{**}}
Name: python-parameterized
Version: 0.7.0
Version: 0.7.1
Release: 0
Summary: Parameterized testing
License: BSD-2-Clause
Url: https://github.com/wolever/parameterized
URL: https://github.com/wolever/parameterized
Source: https://files.pythonhosted.org/packages/source/p/parameterized/parameterized-%{version}.tar.gz
# PATCH-FIX-UPSTREAM skip_Documentation_tests.patch gh#wolever/parameterized#84 mcepl@suse.com
# Skip tests failing with Python 3.8
Patch0: skip_Documentation_tests.patch
BuildRequires: %{python_module mock}
BuildRequires: %{python_module nose2}
BuildRequires: %{python_module nose}
BuildRequires: %{python_module setuptools}
BuildRequires: %{python_module unittest2}
BuildRequires: fdupes
BuildRequires: python-rpm-macros
Suggests: python-nose
Suggests: python-nose2
Suggests: python-unittest2
BuildRequires: fdupes
BuildRequires: python-rpm-macros
BuildArch: noarch
%python_subpackages
%description
@ -45,6 +47,7 @@ Not working with supportest "pytest" versions
%prep
%setup -q -n parameterized-%{version}
%autopatch -p1
%build
%python_build
@ -55,6 +58,7 @@ Not working with supportest "pytest" versions
%check
export LANG=en_US.UTF8
# gh#wolever/parameterized#84
%{python_expand nosetests-%$python_version}
%{python_expand nose2-%$python_version}
%{python_expand unit2-%$python_version}

View File

@ -0,0 +1,20 @@
--- a/parameterized/test.py
+++ b/parameterized/test.py
@@ -2,7 +2,8 @@
import inspect
import mock
-from unittest import TestCase
+import sys
+from unittest import TestCase, skipIf
from nose.tools import assert_equal, assert_raises
from .parameterized import (
@@ -241,6 +242,7 @@ class TestParamerizedOnTestCase(TestCase
missing_tests.remove("%s(%r, bar=%r)" %(expected_name, foo, bar))
+@skipIf(sys.version_info[:2] >= (3, 8), "Doesn't work with Python 3.8")
class TestParameterizedExpandDocstring(TestCase):
def _assert_docstring(self, expected_docstring, rstrip=False):
""" Checks the current test method's docstring. Must be called directly