From: "Michał Górny" <mgorny@gentoo.org>
To: gentoo-commits@lists.gentoo.org
Subject: [gentoo-commits] repo/gentoo:master commit in: dev-python/pytest/, dev-python/pytest/files/
Date: Wed, 11 Jul 2018 22:11:22 +0000 (UTC) [thread overview]
Message-ID: <1531347079.523a3d6756d152fe4063c9e6ccc46e225c0aa55d.mgorny@gentoo> (raw)
commit: 523a3d6756d152fe4063c9e6ccc46e225c0aa55d
Author: Michał Górny <mgorny <AT> gentoo <DOT> org>
AuthorDate: Wed Jul 11 17:35:50 2018 +0000
Commit: Michał Górny <mgorny <AT> gentoo <DOT> org>
CommitDate: Wed Jul 11 22:11:19 2018 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=523a3d67
dev-python/pytest: Add PyPy test fix from Debian
Thanks to sbraz for finding the patch.
.../pytest-3.4.2-pypy-syntaxerror-offset.patch | 27 ++++++++++++++++++++++
dev-python/pytest/pytest-3.4.2.ebuild | 4 ++++
2 files changed, 31 insertions(+)
diff --git a/dev-python/pytest/files/pytest-3.4.2-pypy-syntaxerror-offset.patch b/dev-python/pytest/files/pytest-3.4.2-pypy-syntaxerror-offset.patch
new file mode 100644
index 00000000000..622be56b4e5
--- /dev/null
+++ b/dev-python/pytest/files/pytest-3.4.2-pypy-syntaxerror-offset.patch
@@ -0,0 +1,27 @@
+https://salsa.debian.org/python-team/modules/pytest/commit/405c05a0827592515de76e23c94de1f7773273e6.patch
+
+From 405c05a0827592515de76e23c94de1f7773273e6 Mon Sep 17 00:00:00 2001
+From: =?UTF-8?q?Ond=C5=99ej=20Nov=C3=BD?= <onovy@debian.org>
+Date: Thu, 10 May 2018 11:42:56 +0200
+Subject: [PATCH] Fix PyPy SyntaxError offset in tests
+
+---
+ testing/code/test_source.py | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/testing/code/test_source.py b/testing/code/test_source.py
+index fcce3fa..22278d8 100644
+--- a/testing/code/test_source.py
++++ b/testing/code/test_source.py
+@@ -117,7 +117,7 @@ def test_source_strip_multiline():
+ def test_syntaxerror_rerepresentation():
+ ex = pytest.raises(SyntaxError, _pytest._code.compile, 'xyz xyz')
+ assert ex.value.lineno == 1
+- assert ex.value.offset in (4, 7) # XXX pypy/jython versus cpython?
++ assert ex.value.offset in (4, 5, 7) # XXX pypy/jython versus cpython?
+ assert ex.value.text.strip(), 'x x'
+
+
+--
+2.18.0
+
diff --git a/dev-python/pytest/pytest-3.4.2.ebuild b/dev-python/pytest/pytest-3.4.2.ebuild
index c543591cc90..9fb19f1d81b 100644
--- a/dev-python/pytest/pytest-3.4.2.ebuild
+++ b/dev-python/pytest/pytest-3.4.2.ebuild
@@ -45,6 +45,10 @@ RDEPEND="
!<dev-python/logilab-common-1.3.0"
python_prepare_all() {
+ local PATCHES=(
+ "${FILESDIR}"/pytest-3.4.2-pypy-syntaxerror-offset.patch
+ )
+
chmod o-w *egg*/* || die
# Disable versioning of py.test script to avoid collision with
# versioning performed by the eclass.
next reply other threads:[~2018-07-11 22:11 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-07-11 22:11 Michał Górny [this message]
-- strict thread matches above, loose matches on Subject: below --
2019-07-06 8:43 [gentoo-commits] repo/gentoo:master commit in: dev-python/pytest/, dev-python/pytest/files/ Tim Harder
2019-11-27 13:17 Michał Górny
2020-05-27 6:11 Michał Górny
2021-06-02 19:46 Michał Górny
2021-10-03 19:24 Michał Górny
2022-05-13 12:29 Michał Górny
2024-05-19 11:47 Michał Górny
2024-06-22 15:01 Michał Górny
2025-02-18 12:50 Michał Górny
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
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1531347079.523a3d6756d152fe4063c9e6ccc46e225c0aa55d.mgorny@gentoo \
--to=mgorny@gentoo.org \
--cc=gentoo-commits@lists.gentoo.org \
--cc=gentoo-dev@lists.gentoo.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.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox