unofficial mirror of guix-patches@gnu.org 
 help / color / mirror / code / Atom feed
From: Marius Bakke <mbakke@fastmail.com>
To: 27888@debbugs.gnu.org
Subject: [bug#27888] [PATCH 04/18] gnu: Remove python-pytest@2.
Date: Mon, 31 Jul 2017 22:07:21 +0200	[thread overview]
Message-ID: <20170731200735.28019-4-mbakke@fastmail.com> (raw)
In-Reply-To: <20170731200735.28019-1-mbakke@fastmail.com>

* 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/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): Likewise.
* gnu/packages/web.scm (python-internetarchive): Likewise.
---
 gnu/packages/backup.scm   |  4 +--
 gnu/packages/calendar.scm |  3 +-
 gnu/packages/python.scm   | 86 ++++++++++++++++++-----------------------------
 gnu/packages/web.scm      |  2 +-
 4 files changed, 35 insertions(+), 60 deletions(-)

diff --git a/gnu/packages/backup.scm b/gnu/packages/backup.scm
index 20b375abe..974cc8fe6 100644
--- a/gnu/packages/backup.scm
+++ b/gnu/packages/backup.scm
@@ -534,9 +534,7 @@ detection, and lossless compression.")
     (native-inputs
      `(("python-cython" ,python-cython)
        ("python-setuptools-scm" ,python-setuptools-scm)
-       ;; Borg 1.0.8's test suite uses 'tmpdir_factory', which was introduced in
-       ;; pytest 2.8.
-       ("python-pytest" ,python-pytest-3.0)
+       ("python-pytest" ,python-pytest)
        ;; For generating the documentation.
        ("python-sphinx" ,python-sphinx)
        ("python-sphinx-rtd-theme" ,python-sphinx-rtd-theme)))
diff --git a/gnu/packages/calendar.scm b/gnu/packages/calendar.scm
index b022c0efa..bd2381aed 100644
--- a/gnu/packages/calendar.scm
+++ b/gnu/packages/calendar.scm
@@ -113,8 +113,7 @@ data units.")
                                    "/share/zoneinfo/Zulu"))
             (zero? (system* "py.test" "tests")))))))
     (native-inputs
-      ;; XXX Uses tmpdir_factory, introduced in pytest 2.8.
-     `(("python-pytest" ,python-pytest-3.0)
+     `(("python-pytest" ,python-pytest)
        ("python-pytest-cov" ,python-pytest-cov)
        ("python-setuptools-scm" ,python-setuptools-scm)
        ;; Required for tests
diff --git a/gnu/packages/python.scm b/gnu/packages/python.scm
index dd61389b8..18067d388 100644
--- a/gnu/packages/python.scm
+++ b/gnu/packages/python.scm
@@ -1889,28 +1889,36 @@ code introspection, and logging.")
 (define-public python-pytest
   (package
     (name "python-pytest")
-    (version "2.7.3")
+    (version "3.0.7")
     (source
      (origin
        (method url-fetch)
-       (uri (string-append
-             "https://pypi.python.org/packages/source/p/pytest/pytest-"
-             version ".tar.gz"))
+       (uri (pypi-uri "pytest" version))
        (sha256
         (base32
-         "1z4yi986f9n0p8qmzmn21m21m8j1x78hk3505f89baqm6pdw7afm"))
-       (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):")))))
+         "1asc4b2nd2a4f0g3r12y97rslq5wliji7b73wwkvdrm5s7mrc1mp"))))
     (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
      `(("python-py" ,python-py)))
     (native-inputs
      `(;; Tests need the "regular" bash since 'bash-final' lacks `compgen`.
        ("bash" ,bash)
+       ("python-hypothesis" ,python-hypothesis)
        ("python-nose" ,python-nose)
        ("python-mock" ,python-mock)))
     (home-page "http://pytest.org")
@@ -1919,42 +1927,12 @@ code introspection, and logging.")
      "Pytest is a testing tool that provides auto-discovery of test modules
 and functions, detailed info on failing assert statements, modular fixtures,
 and many external plugins.")
+    (properties `((python2-variant . ,(delay python2-pytest))))
     (license license:expat)))
 
 (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
-                (strip-python2-variant python-pytest-3.0))))
+                (strip-python2-variant python-pytest))))
     (package (inherit base)
       (native-inputs
         `(("python2-enum34" ,python2-enum34)
@@ -3296,7 +3274,7 @@ sources.")
      `(("python-sphinxcontrib-websupport" ,python-sphinxcontrib-websupport)
        ,@(package-propagated-inputs python-sphinx)))
     (native-inputs
-     `(("python-pytest" ,python-pytest-3.0)
+     `(("python-pytest" ,python-pytest)
        ("imagemagick" ,imagemagick) ; for "convert"
        ,@(package-native-inputs python-sphinx)))
     (properties '())))
@@ -3314,7 +3292,7 @@ sources.")
         (base32
          "0kw1axswbvaavr8ggyf4qr6hnisnrzlbkkcdada69vk1x9xjassg"))))
     (native-inputs
-     `(("python-pytest" ,python-pytest-3.0)
+     `(("python-pytest" ,python-pytest)
        ,@(package-native-inputs python-sphinx)))))
 
 (define-public python2-sphinx
@@ -5241,7 +5219,7 @@ cluster without needing to write any wrapper code yourself.")
          (replace 'check (lambda _ (zero? (system* "nosetests" "-v")))))))
     (native-inputs
      `(("python-nose" ,python-nose)
-       ("python-pytest" ,python-pytest-3.0)
+       ("python-pytest" ,python-pytest)
        ("man-db" ,man-db)
        ("which" ,which)
        ("bash-full" ,bash)))                 ;full Bash for 'test_replwrap.py'
@@ -7691,7 +7669,7 @@ responses, rather than doing any computation.")
        ("python-hypothesis" ,python-hypothesis)
        ("python-pretend" ,python-pretend)
        ("python-pytz" ,python-pytz)
-       ("python-pytest" ,python-pytest-3.0)))
+       ("python-pytest" ,python-pytest)))
     (home-page "https://github.com/pyca/cryptography")
     (synopsis "Cryptographic recipes and primitives for Python")
     (description
@@ -7751,7 +7729,7 @@ message digests and key derivation functions.")
     (native-inputs
      `(("python-flaky" ,python-flaky)
        ("python-pretend" ,python-pretend)
-       ("python-pytest" ,python-pytest-3.0)))
+       ("python-pytest" ,python-pytest)))
     (home-page "https://github.com/pyca/pyopenssl")
     (synopsis "Python wrapper module around the OpenSSL library")
     (description
@@ -14493,7 +14471,7 @@ for Flask.")
          "0gf2dpahpl5igb7jh1sr9acj3z3gp7zahqdqb69nk6wx01c8kc1g"))))
     (build-system python-build-system)
     (propagated-inputs
-     `(("pytest" ,python-pytest-3.0)))
+     `(("pytest" ,python-pytest)))
     (home-page "https://github.com/fschulze/pytest-warnings")
     (synopsis "Pytest plugin to list Python warnings in pytest report")
     (description
@@ -14517,7 +14495,7 @@ pytest report.")
          "038049nyjl7di59ycnxvc9nydivc5m8np3hqq84j2iirkccdbs5n"))))
     (build-system python-build-system)
     (propagated-inputs
-     `(("pytest" ,python-pytest-3.0)))
+     `(("pytest" ,python-pytest)))
     (home-page "http://bitbucket.org/memedough/pytest-capturelog/overview")
     (synopsis "Pytest plugin to catch log messages")
     (description
@@ -14542,7 +14520,7 @@ pytest report.")
     (native-inputs
      `(("unzip" ,unzip)))
     (propagated-inputs
-     `(("pytest" ,python-pytest-3.0)))
+     `(("pytest" ,python-pytest)))
     (home-page "https://github.com/eisensheng/pytest-catchlog")
     (synopsis "Pytest plugin to catch log messages")
     (description
@@ -15533,7 +15511,7 @@ address is valid and really exists.")
      `(("python-dateutil" ,python-dateutil)
        ("python-simplejson" ,python-simplejson)))
     (native-inputs
-     `(("python-pytest-3.0" ,python-pytest-3.0)
+     `(("python-pytest" ,python-pytest)
        ("python-pytz" ,python-pytz)))
     (home-page "https://github.com/marshmallow-code/marshmallow")
     (synopsis "Convert complex datatypes to and from native
@@ -15580,7 +15558,7 @@ complex datatypes to and from native Python datatypes.")
     (propagated-inputs
      `(("python-pyyaml" ,python-pyyaml)))
     (native-inputs
-     `(("python-pytest-3.0" ,python-pytest-3.0)
+     `(("python-pytest" ,python-pytest)
        ("python-flask" ,python-flask)
        ("python-marshmallow" ,python-marshmallow)
        ("python-tornado" ,python-tornado)
@@ -15633,7 +15611,7 @@ Swagger 2.0).")
        ("python-flake8" ,python-flake8)
        ("python-flask-restful" ,python-flask-restful)
        ("python-flex" ,python-flex)
-       ("python-pytest-3.0" ,python-pytest-3.0)
+       ("python-pytest" ,python-pytest)
        ("python-pytest-cov" ,python-pytest-cov)
        ("python-marshmallow" ,python-marshmallow)
        ("python-apispec" ,python-apispec)))
diff --git a/gnu/packages/web.scm b/gnu/packages/web.scm
index 9c3373f8d..f691705d5 100644
--- a/gnu/packages/web.scm
+++ b/gnu/packages/web.scm
@@ -4763,7 +4763,7 @@ command-line arguments or read from stdin.")
        ("python-schema" ,python-schema-0.5)
        ("python-backports-csv" ,python-backports-csv)))
     (native-inputs
-     `(("python-pytest-3.0" ,python-pytest-3.0)
+     `(("python-pytest" ,python-pytest)
        ("python-pytest-capturelog" ,python-pytest-capturelog)
        ("python-responses" ,python-responses)))
     (home-page "https://github.com/jjjake/internetarchive")
-- 
2.13.3

  parent reply	other threads:[~2017-07-31 20:08 UTC|newest]

Thread overview: 26+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <handler.27888.B.150153147718000.ack@debbugs.gnu.org>
2017-07-31 20:07 ` [bug#27888] [PATCH 01/18] gnu: python@3: Update to 3.6.2 Marius Bakke
2017-07-31 20:07   ` [bug#27888] [PATCH 02/18] gnu: python-py: Update to 1.4.34 Marius Bakke
2017-07-31 20:07   ` [bug#27888] [PATCH 03/18] gnu: python-six: Really enable tests Marius Bakke
2017-07-31 20:07   ` Marius Bakke [this message]
2017-07-31 20:07   ` [bug#27888] [PATCH 05/18] gnu: python-pytest: Add a minimal variant for bootstrapping Marius Bakke
2017-07-31 20:07   ` [bug#27888] [PATCH 06/18] gnu: python-setuptools-scm: Update to 1.15.6 Marius Bakke
2017-07-31 20:07   ` [bug#27888] [PATCH 07/18] gnu: python-pytest: Update to 3.1.3 Marius Bakke
2017-07-31 20:07   ` [bug#27888] [PATCH 08/18] gnu: python-pyflakes: Update to 1.5.0 Marius Bakke
2017-07-31 20:07   ` [bug#27888] [PATCH 09/18] gnu: python-mccabe: Update to 0.6.1 Marius Bakke
2017-07-31 20:07   ` [bug#27888] [PATCH 10/18] gnu: python-mock@2: Add dependency on python-six Marius Bakke
2017-07-31 20:07   ` [bug#27888] [PATCH 11/18] gnu: Add python2-enum Marius Bakke
2017-07-31 20:07   ` [bug#27888] [PATCH 12/18] gnu: python-flake8: Update to 3.4.1 Marius Bakke
2017-07-31 20:07   ` [bug#27888] [PATCH 13/18] gnu: Add python-linecache2 Marius Bakke
2017-07-31 20:07   ` [bug#27888] [PATCH 14/18] gnu: Add python-traceback2 Marius Bakke
2017-07-31 20:07   ` [bug#27888] [PATCH 15/18] gnu: python-unittest2: Update to 1.1.0 Marius Bakke
2017-07-31 20:07   ` [bug#27888] [PATCH 16/18] gnu: Add python2-funcsigs Marius Bakke
2017-07-31 20:07   ` [bug#27888] [PATCH 17/18] gnu: python-mock: Make 2.0 the default package Marius Bakke
2017-07-31 20:45     ` Marius Bakke
2017-07-31 20:07   ` [bug#27888] [PATCH 18/18] gnu: python-hypothesis: Update to 3.14.0 Marius Bakke
2017-07-31 23:07   ` [bug#27888] [PATCH 01/18] gnu: python@3: Update to 3.6.2 Leo Famulari
2017-08-01  0:30     ` Marius Bakke
2017-10-18 21:17       ` Ricardo Wurmus
2017-10-18 22:30         ` bug#27888: " Marius Bakke
2017-10-18 23:36           ` [bug#27888] " Cyril Roelandt
2017-10-19 18:15             ` Marius Bakke
2017-10-19  7:58           ` Ricardo Wurmus

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://guix.gnu.org/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20170731200735.28019-4-mbakke@fastmail.com \
    --to=mbakke@fastmail.com \
    --cc=27888@debbugs.gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/guix.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).