[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
03/16: gnu: python-parameterized: Update to 0.7.1.
From: |
guix-commits |
Subject: |
03/16: gnu: python-parameterized: Update to 0.7.1. |
Date: |
Mon, 20 Jan 2020 17:00:01 -0500 (EST) |
mbakke pushed a commit to branch master
in repository guix.
commit ae3909eb4c36255834b5780ad8aa29055181c964
Author: Marius Bakke <address@hidden>
AuthorDate: Sun Jan 19 20:36:24 2020 +0100
gnu: python-parameterized: Update to 0.7.1.
* gnu/packages/patches/python2-parameterized-docstring-test.patch: New file.
* gnu/local.mk (dist_patch_DATA): Adjust accordingly.
* gnu/packages/check.scm (python-parameterized): Update to 0.7.1.
[arguments]: Remove #:tests?. Add #:phases to override 'check' phase.
[native-inputs]: Add PYTHON-MOCK and PYTHON-NOSE.
[properties]: New field.
(python2-parameterized)[source](patches): New field.
---
gnu/local.mk | 1 +
gnu/packages/check.scm | 26 ++++++++++++++++++----
.../python2-parameterized-docstring-test.patch | 18 +++++++++++++++
3 files changed, 41 insertions(+), 4 deletions(-)
diff --git a/gnu/local.mk b/gnu/local.mk
index 59589f2..c0aa92c 100644
--- a/gnu/local.mk
+++ b/gnu/local.mk
@@ -1321,6 +1321,7 @@ dist_patch_DATA =
\
%D%/packages/patches/python-mox3-python3.6-compat.patch \
%D%/packages/patches/python-testtools.patch \
%D%/packages/patches/python-packaging-test-arch.patch \
+ %D%/packages/patches/python2-parameterized-docstring-test.patch \
%D%/packages/patches/python-paste-remove-timing-test.patch \
%D%/packages/patches/python-pycrypto-CVE-2013-7459.patch \
%D%/packages/patches/python2-pygobject-2-gi-info-type-error-domain.patch \
diff --git a/gnu/packages/check.scm b/gnu/packages/check.scm
index 5554965..e10e684 100644
--- a/gnu/packages/check.scm
+++ b/gnu/packages/check.scm
@@ -580,25 +580,43 @@ but it works for any C/C++ project.")
(define-public python-parameterized
(package
(name "python-parameterized")
- (version "0.6.1")
+ (version "0.7.1")
(source
(origin
(method url-fetch)
(uri (pypi-uri "parameterized" version))
(sha256
(base32
- "1qj1939shm48d9ql6fm1nrdy4p7sdyj8clz1szh5swwpf1qqxxfa"))))
+ "1vapry9lyfb2mlpgk2wh9079hzxzq5120bsczncxxay663mdp53a"))))
(build-system python-build-system)
- (arguments '(#:tests? #f)) ; there are no tests
+ (arguments
+ '(#:phases (modify-phases %standard-phases
+ (replace 'check
+ (lambda* (#:key tests? #:allow-other-keys)
+ (if tests?
+ (invoke "nosetests" "-v")
+ (format #t "test suite not run~%"))
+ #t)))))
+ (native-inputs
+ `(("python-mock" ,python-mock)
+ ("python-nose" ,python-nose)))
(home-page "https://github.com/wolever/parameterized")
(synopsis "Parameterized testing with any Python test framework")
(description
"Parameterized is a Python library that aims to fix parameterized testing
for every Python test framework. It supports nose, py.test, and unittest.")
+ (properties `((python2-variant . ,(delay python2-parameterized))))
(license license:bsd-2)))
(define-public python2-parameterized
- (package-with-python2 python-parameterized))
+ (let ((base (package-with-python2 (strip-python2-variant
+ python-parameterized))))
+ (package/inherit
+ base
+ (source
+ (origin
+ (inherit (package-source base))
+ (patches (search-patches
"python2-parameterized-docstring-test.patch")))))))
(define-public python-minimock
(package
diff --git a/gnu/packages/patches/python2-parameterized-docstring-test.patch
b/gnu/packages/patches/python2-parameterized-docstring-test.patch
new file mode 100644
index 0000000..14691e1
--- /dev/null
+++ b/gnu/packages/patches/python2-parameterized-docstring-test.patch
@@ -0,0 +1,18 @@
+Skip unicode docstring test, required when running on Python 2.
+
+See <https://github.com/wolever/parameterized/issues/44>.
+
+--- a/parameterized/test.py
++++ b/parameterized/test.py
+@@ -284,11 +284,6 @@
+ " More" %(foo, )
+ )
+
+- @parameterized.expand([param("foo")])
+- def test_unicode_docstring(self, foo):
+- u"""Döcumentation."""
+- self._assert_docstring(u"Döcumentation [with foo=%r]." %(foo, ))
+-
+ @parameterized.expand([param("foo", )])
+ def test_default_values_get_correct_value(self, foo, bar=12):
+ """Documentation"""
- branch master updated (aa10ad7 -> 2562364), guix-commits, 2020/01/20
- 01/16: gnu: python-packaging: Add comment about upstream patch status., guix-commits, 2020/01/20
- 02/16: gnu: Add python-anytree., guix-commits, 2020/01/20
- 04/16: gnu: snappy: Update to 1.1.8., guix-commits, 2020/01/20
- 07/16: gnu: libvpx: Update to 1.8.2., guix-commits, 2020/01/20
- 05/16: gnu: e2fsprogs: Update to 1.45.5., guix-commits, 2020/01/20
- 06/16: gnu: re2: Update to 2020-01-01., guix-commits, 2020/01/20
- 09/16: gnu: libsrtp: Update to 2.3.0., guix-commits, 2020/01/20
- 14/16: gnu: stepmania: Build with libjpeg-turbo., guix-commits, 2020/01/20
- 08/16: gnu: ffmpeg: Update to 4.2.2., guix-commits, 2020/01/20
- 03/16: gnu: python-parameterized: Update to 0.7.1.,
guix-commits <=
- 11/16: gnu: xorg-server: Update to 1.20.7., guix-commits, 2020/01/20
- 10/16: gnu: libsrtp: Build shared library., guix-commits, 2020/01/20
- 12/16: gnu: mailutils: Update to 3.8., guix-commits, 2020/01/20
- 15/16: gnu: qt@4: Build with libjpeg-turbo., guix-commits, 2020/01/20
- 16/16: gnu: guile-git: Update to 0.3.0., guix-commits, 2020/01/20
- 13/16: gnu: mame: Build with libjpeg-turbo., guix-commits, 2020/01/20