mirror of
https://git.in.rschanz.org/ryan77627/guix.git
synced 2024-11-07 15:36:20 -05:00
gnu: python-chardet: Enable tests.
* gnu/packages/python-xyz.scm (python-chardet) [source]: Add upstream patch. [arguments]: Remove. * gnu/packages/patches/python-chardet-3.0.4-pytest.patch: New file. * gnu/local.mk (dist_patch_DATA): Add it. Signed-off-by: Marius Bakke <marius@gnu.org>
This commit is contained in:
parent
3182d629a2
commit
331aaf5280
3 changed files with 18 additions and 3 deletions
|
@ -1491,6 +1491,7 @@ dist_patch_DATA = \
|
|||
%D%/packages/patches/python-argcomplete-1.11.1-fish31.patch \
|
||||
%D%/packages/patches/python-axolotl-AES-fix.patch \
|
||||
%D%/packages/patches/python-cairocffi-dlopen-path.patch \
|
||||
%D%/packages/patches/python-chardet-3.0.4-pytest.patch \
|
||||
%D%/packages/patches/python-cross-compile.patch \
|
||||
%D%/packages/patches/python2-larch-coverage-4.0a6-compatibility.patch \
|
||||
%D%/packages/patches/python-configobj-setuptools.patch \
|
||||
|
|
15
gnu/packages/patches/python-chardet-3.0.4-pytest.patch
Normal file
15
gnu/packages/patches/python-chardet-3.0.4-pytest.patch
Normal file
|
@ -0,0 +1,15 @@
|
|||
Fix test failure with Pytest 4.
|
||||
|
||||
Taken from upstream:
|
||||
https://github.com/chardet/chardet/commit/440828f8faafdb58700c64a9ea8f6a30b154c08b
|
||||
|
||||
diff --git a/test.py b/test.py
|
||||
--- a/test.py
|
||||
+++ b/test.py
|
||||
@@ -59,5 +59,5 @@ def gen_test_params():
|
||||
full_path = join(path, file_name)
|
||||
test_case = full_path, encoding
|
||||
if full_path in EXPECTED_FAILURES:
|
||||
- test_case = pytest.mark.xfail(test_case)
|
||||
+ test_case = pytest.param(*test_case, marks=pytest.mark.xfail)
|
||||
yield test_case
|
|
@ -10059,14 +10059,13 @@ (define-public python-chardet
|
|||
(uri (pypi-uri "chardet" version))
|
||||
(sha256
|
||||
(base32
|
||||
"1bpalpia6r5x1kknbk11p1fzph56fmmnp405ds8icksd3knr5aw4"))))
|
||||
"1bpalpia6r5x1kknbk11p1fzph56fmmnp405ds8icksd3knr5aw4"))
|
||||
(patches (search-patches "python-chardet-3.0.4-pytest.patch"))))
|
||||
(native-inputs
|
||||
`(("python-hypothesis" ,python-hypothesis)
|
||||
("python-pytest" ,python-pytest)
|
||||
("python-pytest-runner" ,python-pytest-runner)))
|
||||
(build-system python-build-system)
|
||||
;; XXX: Incompatible with Pytest 4: <https://github.com/chardet/chardet/issues/173>.
|
||||
(arguments `(#:tests? #f))
|
||||
(home-page "https://github.com/chardet/chardet")
|
||||
(synopsis "Universal encoding detector for Python 2 and 3")
|
||||
(description
|
||||
|
|
Loading…
Reference in a new issue