gnu: Remove python-pytest@2.

* gnu/packages/python.scm (python-pytest): Update to 3.0.7.
[source]: Move substitution to ...
[arguments]: ... here. Incorporate phase from pytest-3.0.
[native-inputs]: Add PYTHON-HYPOTHESIS.
(python-pytest-3.0): Remove variable.
(python2-pytest-3.0): Rename to ...
(python2-pytest): ... this.
[native-inputs]: Add PYTHON2-ENUM34.
* gnu/packages/backup.scm (borg)[native-inputs]: Replace PYTHON-PYTEST-3.0
with PYTHON-PYTEST.
* gnu/packages/calendar.scm (khal): Likewise.
* gnu/packages/databases.scm (python-orator): Likewise.
* gnu/packages/python.scm (python-sphinx-1.6, python-sphinx-1.5.3,
python-pexpect, python-cryptography, python-pyopenssl, python-pytest-warnings,
python-pytest-capturelog, python-pytest-catchlog, python-marshmallow,
python-apispec, python-flasgger, python-pyjwt, python-grako,
python-honcho): Likewise.
* gnu/packages/web.scm (python-internetarchive): Likewise.
This commit is contained in:
Marius Bakke 2017-07-30 19:25:26 +02:00
parent 8ed675a77f
commit 928da609b5
No known key found for this signature in database
GPG Key ID: A2A06DF2A33A54FA
5 changed files with 39 additions and 64 deletions

View File

@ -535,9 +535,7 @@ detection, and lossless compression.")
(native-inputs (native-inputs
`(("python-cython" ,python-cython) `(("python-cython" ,python-cython)
("python-setuptools-scm" ,python-setuptools-scm) ("python-setuptools-scm" ,python-setuptools-scm)
;; Borg 1.0.8's test suite uses 'tmpdir_factory', which was introduced in ("python-pytest" ,python-pytest)
;; pytest 2.8.
("python-pytest" ,python-pytest-3.0)
;; For generating the documentation. ;; For generating the documentation.
("python-sphinx" ,python-sphinx) ("python-sphinx" ,python-sphinx)
("python-guzzle-sphinx-theme" ,python-guzzle-sphinx-theme))) ("python-guzzle-sphinx-theme" ,python-guzzle-sphinx-theme)))

View File

@ -118,8 +118,7 @@ data units.")
"not test_printics_read_from_stdin " "not test_printics_read_from_stdin "
"and not test_import_from_stdin")))))))) "and not test_import_from_stdin"))))))))
(native-inputs (native-inputs
;; XXX Uses tmpdir_factory, introduced in pytest 2.8. `(("python-pytest" ,python-pytest)
`(("python-pytest" ,python-pytest-3.0)
("python-pytest-cov" ,python-pytest-cov) ("python-pytest-cov" ,python-pytest-cov)
("python-setuptools-scm" ,python-setuptools-scm) ("python-setuptools-scm" ,python-setuptools-scm)
;; Required for tests ;; Required for tests

View File

@ -1798,7 +1798,7 @@ Memory-Mapped Database} (LMDB), a high-performance key-value store.")
#t))))) #t)))))
(native-inputs (native-inputs
`(("python-pytest-mock" ,python-pytest-mock) `(("python-pytest-mock" ,python-pytest-mock)
("python-pytest" ,python-pytest-3.0) ("python-pytest" ,python-pytest)
("python-flexmock" ,python-flexmock))) ("python-flexmock" ,python-flexmock)))
(propagated-inputs (propagated-inputs
`(("python-backpack" ,python-backpack) `(("python-backpack" ,python-backpack)

View File

@ -1920,28 +1920,36 @@ code introspection, and logging.")
(define-public python-pytest (define-public python-pytest
(package (package
(name "python-pytest") (name "python-pytest")
(version "2.7.3") (version "3.0.7")
(source (source
(origin (origin
(method url-fetch) (method url-fetch)
(uri (string-append (uri (pypi-uri "pytest" version))
"https://pypi.python.org/packages/source/p/pytest/pytest-"
version ".tar.gz"))
(sha256 (sha256
(base32 (base32
"1z4yi986f9n0p8qmzmn21m21m8j1x78hk3505f89baqm6pdw7afm")) "1asc4b2nd2a4f0g3r12y97rslq5wliji7b73wwkvdrm5s7mrc1mp"))))
(modules '((guix build utils)))
(snippet
;; One of the tests involves the /usr directory, so it fails.
'(substitute* "testing/test_argcomplete.py"
(("def test_remove_dir_prefix\\(self\\):")
"@pytest.mark.xfail\n def test_remove_dir_prefix(self):")))))
(build-system python-build-system) (build-system python-build-system)
(arguments
`(#:phases
(modify-phases %standard-phases
(add-before 'check 'disable-invalid-tests
(lambda _
;; Some tests involves the /usr directory, and fails.
(substitute* "testing/test_argcomplete.py"
(("def test_remove_dir_prefix\\(self\\):")
"@pytest.mark.xfail\n def test_remove_dir_prefix(self):"))
(substitute* "testing/test_argcomplete.py"
(("def test_remove_dir_prefix" line)
(string-append "@pytest.mark.skip"
"(reason=\"Assumes that /usr exists.\")\n "
line)))
#t)))))
(propagated-inputs (propagated-inputs
`(("python-py" ,python-py))) `(("python-py" ,python-py)))
(native-inputs (native-inputs
`(;; Tests need the "regular" bash since 'bash-final' lacks `compgen`. `(;; Tests need the "regular" bash since 'bash-final' lacks `compgen`.
("bash" ,bash) ("bash" ,bash)
("python-hypothesis" ,python-hypothesis)
("python-nose" ,python-nose) ("python-nose" ,python-nose)
("python-mock" ,python-mock))) ("python-mock" ,python-mock)))
(home-page "http://pytest.org") (home-page "http://pytest.org")
@ -1950,42 +1958,12 @@ code introspection, and logging.")
"Pytest is a testing tool that provides auto-discovery of test modules "Pytest is a testing tool that provides auto-discovery of test modules
and functions, detailed info on failing assert statements, modular fixtures, and functions, detailed info on failing assert statements, modular fixtures,
and many external plugins.") and many external plugins.")
(properties `((python2-variant . ,(delay python2-pytest))))
(license license:expat))) (license license:expat)))
(define-public python2-pytest (define-public python2-pytest
(package-with-python2 python-pytest))
;; Some packages require a newer pytest.
(define-public python-pytest-3.0
(package
(inherit python-pytest)
(name "python-pytest")
(version "3.0.7")
(source (origin
(method url-fetch)
(uri (pypi-uri "pytest" version))
(sha256
(base32
"1asc4b2nd2a4f0g3r12y97rslq5wliji7b73wwkvdrm5s7mrc1mp"))))
(arguments
`(#:phases
(modify-phases %standard-phases
(add-before 'check 'disable-invalid-test
(lambda _
(substitute* "testing/test_argcomplete.py"
(("def test_remove_dir_prefix" line)
(string-append "@pytest.mark.skip"
"(reason=\"Assumes that /usr exists.\")\n "
line)))
#t)))))
(native-inputs
`(("python-hypothesis" ,python-hypothesis)
,@(package-native-inputs python-pytest)))
(properties `((python2-variant . ,(delay python2-pytest-3.0))))))
(define-public python2-pytest-3.0
(let ((base (package-with-python2 (let ((base (package-with-python2
(strip-python2-variant python-pytest-3.0)))) (strip-python2-variant python-pytest))))
(package (inherit base) (package (inherit base)
(native-inputs (native-inputs
`(("python2-enum34" ,python2-enum34) `(("python2-enum34" ,python2-enum34)
@ -2888,7 +2866,7 @@ somewhat intelligible.")
#t)))) #t))))
(build-system python-build-system) (build-system python-build-system)
(native-inputs (native-inputs
`(("python-pytest" ,python-pytest-3.0) `(("python-pytest" ,python-pytest)
("python-pytest-cov" ,python-pytest-cov) ("python-pytest-cov" ,python-pytest-cov)
("python-pytest-runner" ,python-pytest-runner))) ("python-pytest-runner" ,python-pytest-runner)))
(home-page "https://github.com/progrium/pyjwt") (home-page "https://github.com/progrium/pyjwt")
@ -3344,7 +3322,7 @@ sources.")
`(("python-sphinxcontrib-websupport" ,python-sphinxcontrib-websupport) `(("python-sphinxcontrib-websupport" ,python-sphinxcontrib-websupport)
,@(package-propagated-inputs python-sphinx))) ,@(package-propagated-inputs python-sphinx)))
(native-inputs (native-inputs
`(("python-pytest" ,python-pytest-3.0) `(("python-pytest" ,python-pytest)
("imagemagick" ,imagemagick) ; for "convert" ("imagemagick" ,imagemagick) ; for "convert"
,@(package-native-inputs python-sphinx))) ,@(package-native-inputs python-sphinx)))
(properties '()))) (properties '())))
@ -3362,7 +3340,7 @@ sources.")
(base32 (base32
"0kw1axswbvaavr8ggyf4qr6hnisnrzlbkkcdada69vk1x9xjassg")))) "0kw1axswbvaavr8ggyf4qr6hnisnrzlbkkcdada69vk1x9xjassg"))))
(native-inputs (native-inputs
`(("python-pytest" ,python-pytest-3.0) `(("python-pytest" ,python-pytest)
,@(package-native-inputs python-sphinx))))) ,@(package-native-inputs python-sphinx)))))
(define-public python2-sphinx (define-public python2-sphinx
@ -5313,7 +5291,7 @@ Python language binding specification.")
(arguments '(#:tests? #f)) ; Test file 'grako.ebnf' is missing from archive. (arguments '(#:tests? #f)) ; Test file 'grako.ebnf' is missing from archive.
(native-inputs (native-inputs
`(("unzip" ,unzip) `(("unzip" ,unzip)
("python-pytest" ,python-pytest-3.0) ("python-pytest" ,python-pytest)
("python-pytest-runner" ,python-pytest-runner))) ("python-pytest-runner" ,python-pytest-runner)))
(home-page "https://bitbucket.org/neogeny/grako") (home-page "https://bitbucket.org/neogeny/grako")
(synopsis "EBNF parser generator") (synopsis "EBNF parser generator")
@ -5371,7 +5349,7 @@ cluster without needing to write any wrapper code yourself.")
(base32 "0zizn61n5z5hq421hkypk9pw8s6fpxw30f4hsg7k4ivwzy3gjw9j")))) (base32 "0zizn61n5z5hq421hkypk9pw8s6fpxw30f4hsg7k4ivwzy3gjw9j"))))
(build-system python-build-system) (build-system python-build-system)
(native-inputs (native-inputs
`(("python-pytest" ,python-pytest-3.0) `(("python-pytest" ,python-pytest)
("python-mock" ,python-mock) ("python-mock" ,python-mock)
("python-tox" ,python-tox) ("python-tox" ,python-tox)
("which" ,which))) ;for tests ("which" ,which))) ;for tests
@ -5434,7 +5412,7 @@ displayed.")
(replace 'check (lambda _ (zero? (system* "nosetests" "-v"))))))) (replace 'check (lambda _ (zero? (system* "nosetests" "-v")))))))
(native-inputs (native-inputs
`(("python-nose" ,python-nose) `(("python-nose" ,python-nose)
("python-pytest" ,python-pytest-3.0) ("python-pytest" ,python-pytest)
("man-db" ,man-db) ("man-db" ,man-db)
("which" ,which) ("which" ,which)
("bash-full" ,bash))) ;full Bash for 'test_replwrap.py' ("bash-full" ,bash))) ;full Bash for 'test_replwrap.py'
@ -8013,7 +7991,7 @@ responses, rather than doing any computation.")
("python-hypothesis" ,python-hypothesis) ("python-hypothesis" ,python-hypothesis)
("python-pretend" ,python-pretend) ("python-pretend" ,python-pretend)
("python-pytz" ,python-pytz) ("python-pytz" ,python-pytz)
("python-pytest" ,python-pytest-3.0))) ("python-pytest" ,python-pytest)))
(home-page "https://github.com/pyca/cryptography") (home-page "https://github.com/pyca/cryptography")
(synopsis "Cryptographic recipes and primitives for Python") (synopsis "Cryptographic recipes and primitives for Python")
(description (description
@ -8073,7 +8051,7 @@ message digests and key derivation functions.")
(native-inputs (native-inputs
`(("python-flaky" ,python-flaky) `(("python-flaky" ,python-flaky)
("python-pretend" ,python-pretend) ("python-pretend" ,python-pretend)
("python-pytest" ,python-pytest-3.0))) ("python-pytest" ,python-pytest)))
(home-page "https://github.com/pyca/pyopenssl") (home-page "https://github.com/pyca/pyopenssl")
(synopsis "Python wrapper module around the OpenSSL library") (synopsis "Python wrapper module around the OpenSSL library")
(description (description
@ -15043,7 +15021,7 @@ for Flask.")
"0gf2dpahpl5igb7jh1sr9acj3z3gp7zahqdqb69nk6wx01c8kc1g")))) "0gf2dpahpl5igb7jh1sr9acj3z3gp7zahqdqb69nk6wx01c8kc1g"))))
(build-system python-build-system) (build-system python-build-system)
(propagated-inputs (propagated-inputs
`(("pytest" ,python-pytest-3.0))) `(("pytest" ,python-pytest)))
(home-page "https://github.com/fschulze/pytest-warnings") (home-page "https://github.com/fschulze/pytest-warnings")
(synopsis "Pytest plugin to list Python warnings in pytest report") (synopsis "Pytest plugin to list Python warnings in pytest report")
(description (description
@ -15067,7 +15045,7 @@ pytest report.")
"038049nyjl7di59ycnxvc9nydivc5m8np3hqq84j2iirkccdbs5n")))) "038049nyjl7di59ycnxvc9nydivc5m8np3hqq84j2iirkccdbs5n"))))
(build-system python-build-system) (build-system python-build-system)
(propagated-inputs (propagated-inputs
`(("pytest" ,python-pytest-3.0))) `(("pytest" ,python-pytest)))
(home-page "http://bitbucket.org/memedough/pytest-capturelog/overview") (home-page "http://bitbucket.org/memedough/pytest-capturelog/overview")
(synopsis "Pytest plugin to catch log messages") (synopsis "Pytest plugin to catch log messages")
(description (description
@ -15092,7 +15070,7 @@ pytest report.")
(native-inputs (native-inputs
`(("unzip" ,unzip))) `(("unzip" ,unzip)))
(propagated-inputs (propagated-inputs
`(("pytest" ,python-pytest-3.0))) `(("pytest" ,python-pytest)))
(home-page "https://github.com/eisensheng/pytest-catchlog") (home-page "https://github.com/eisensheng/pytest-catchlog")
(synopsis "Pytest plugin to catch log messages") (synopsis "Pytest plugin to catch log messages")
(description (description
@ -16083,7 +16061,7 @@ address is valid and really exists.")
`(("python-dateutil" ,python-dateutil) `(("python-dateutil" ,python-dateutil)
("python-simplejson" ,python-simplejson))) ("python-simplejson" ,python-simplejson)))
(native-inputs (native-inputs
`(("python-pytest-3.0" ,python-pytest-3.0) `(("python-pytest" ,python-pytest)
("python-pytz" ,python-pytz))) ("python-pytz" ,python-pytz)))
(home-page "https://github.com/marshmallow-code/marshmallow") (home-page "https://github.com/marshmallow-code/marshmallow")
(synopsis "Convert complex datatypes to and from native (synopsis "Convert complex datatypes to and from native
@ -16130,7 +16108,7 @@ complex datatypes to and from native Python datatypes.")
(propagated-inputs (propagated-inputs
`(("python-pyyaml" ,python-pyyaml))) `(("python-pyyaml" ,python-pyyaml)))
(native-inputs (native-inputs
`(("python-pytest-3.0" ,python-pytest-3.0) `(("python-pytest" ,python-pytest)
("python-flask" ,python-flask) ("python-flask" ,python-flask)
("python-marshmallow" ,python-marshmallow) ("python-marshmallow" ,python-marshmallow)
("python-tornado" ,python-tornado) ("python-tornado" ,python-tornado)
@ -16183,7 +16161,7 @@ Swagger 2.0).")
("python-flake8" ,python-flake8) ("python-flake8" ,python-flake8)
("python-flask-restful" ,python-flask-restful) ("python-flask-restful" ,python-flask-restful)
("python-flex" ,python-flex) ("python-flex" ,python-flex)
("python-pytest-3.0" ,python-pytest-3.0) ("python-pytest" ,python-pytest)
("python-pytest-cov" ,python-pytest-cov) ("python-pytest-cov" ,python-pytest-cov)
("python-marshmallow" ,python-marshmallow) ("python-marshmallow" ,python-marshmallow)
("python-apispec" ,python-apispec))) ("python-apispec" ,python-apispec)))

View File

@ -5081,7 +5081,7 @@ command-line arguments or read from stdin.")
("python-schema" ,python-schema-0.5) ("python-schema" ,python-schema-0.5)
("python-backports-csv" ,python-backports-csv))) ("python-backports-csv" ,python-backports-csv)))
(native-inputs (native-inputs
`(("python-pytest-3.0" ,python-pytest-3.0) `(("python-pytest" ,python-pytest)
("python-pytest-capturelog" ,python-pytest-capturelog) ("python-pytest-capturelog" ,python-pytest-capturelog)
("python-responses" ,python-responses))) ("python-responses" ,python-responses)))
(home-page "https://github.com/jjjake/internetarchive") (home-page "https://github.com/jjjake/internetarchive")