public inbox for gentoo-commits@lists.gentoo.org
 help / color / mirror / Atom feed
From: "Michał Górny" <mgorny@gentoo.org>
To: gentoo-commits@lists.gentoo.org
Subject: [gentoo-commits] repo/gentoo:master commit in: dev-python/zope-testrunner/files/, dev-python/zope-testrunner/
Date: Mon, 31 May 2021 12:09:44 +0000 (UTC)	[thread overview]
Message-ID: <1622461615.2990366dbf3fe43fba228ef3d3701cd4b453346c.mgorny@gentoo> (raw)

commit:     2990366dbf3fe43fba228ef3d3701cd4b453346c
Author:     Zamarin Arthur <arthurzam <AT> gmail <DOT> com>
AuthorDate: Sun May 23 08:55:07 2021 +0000
Commit:     Michał Górny <mgorny <AT> gentoo <DOT> org>
CommitDate: Mon May 31 11:46:55 2021 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=2990366d

dev-python/zope-testrunner: bump to python 3.10

fix tests for python3.10
passes tests

Signed-off-by: Zamarin Arthur <arthurzam <AT> gmail.com>
Signed-off-by: Michał Górny <mgorny <AT> gentoo.org>

 .../zope-testrunner-5.3.0-fix-test-py3.10.patch    | 64 ++++++++++++++++++++++
 .../zope-testrunner/zope-testrunner-5.3.0.ebuild   | 10 +++-
 2 files changed, 71 insertions(+), 3 deletions(-)

diff --git a/dev-python/zope-testrunner/files/zope-testrunner-5.3.0-fix-test-py3.10.patch b/dev-python/zope-testrunner/files/zope-testrunner-5.3.0-fix-test-py3.10.patch
new file mode 100644
index 00000000000..6d495ba2cf5
--- /dev/null
+++ b/dev-python/zope-testrunner/files/zope-testrunner-5.3.0-fix-test-py3.10.patch
@@ -0,0 +1,64 @@
+From af8bfec49d90613633b76e914a6f54884463ba94 Mon Sep 17 00:00:00 2001
+From: Jerry James <loganjerry@gmail.com>
+Date: Mon, 10 May 2021 09:55:23 -0600
+Subject: [PATCH] Adapt to python 3.10 SyntaxError messages
+
+---
+ .../testrunner/tests/testrunner-debugging-import-failure.rst    | 2 +-
+ src/zope/testrunner/tests/testrunner-errors.rst                 | 2 +-
+ src/zope/testrunner/tests/testrunner-subunit-v2.rst             | 2 +-
+ src/zope/testrunner/tests/testrunner-subunit.rst                | 2 +-
+ 4 files changed, 4 insertions(+), 4 deletions(-)
+
+diff --git a/src/zope/testrunner/tests/testrunner-debugging-import-failure.rst b/src/zope/testrunner/tests/testrunner-debugging-import-failure.rst
+index 1613cb9..c0b2aee 100644
+--- a/src/zope/testrunner/tests/testrunner-debugging-import-failure.rst
++++ b/src/zope/testrunner/tests/testrunner-debugging-import-failure.rst
+@@ -41,7 +41,7 @@ Post-mortem debugging also works when there is an import failure.
+       File ".../TESTS-DIR/tests.py", line 2
+         impot doctest
+                     ^
+-    SyntaxError: invalid syntax
++    SyntaxError: invalid syntax...
+     > ...find.py(399)import_name()
+     -> __import__(name)
+     (Pdb) c
+diff --git a/src/zope/testrunner/tests/testrunner-errors.rst b/src/zope/testrunner/tests/testrunner-errors.rst
+index e210fe3..05d74b8 100644
+--- a/src/zope/testrunner/tests/testrunner-errors.rst
++++ b/src/zope/testrunner/tests/testrunner-errors.rst
+@@ -818,7 +818,7 @@ Then run the tests:
+       File "testrunner-ex/sample2/sampletests_i.py", line 1
+         importx unittest
+                        ^
+-    SyntaxError: invalid syntax
++    SyntaxError: invalid syntax...
+     <BLANKLINE>
+     <BLANKLINE>
+     Module: sample2.sample21.sampletests_i
+diff --git a/src/zope/testrunner/tests/testrunner-subunit-v2.rst b/src/zope/testrunner/tests/testrunner-subunit-v2.rst
+index 8658fe3..c165b23 100644
+--- a/src/zope/testrunner/tests/testrunner-subunit-v2.rst
++++ b/src/zope/testrunner/tests/testrunner-subunit-v2.rst
+@@ -447,7 +447,7 @@ Let's run tests including a module with some bad syntax:
+       File "/home/benji/workspace/all-the-trunks/zope.testrunner/src/zope/testrunner/testrunner-ex/sample2/badsyntax.py", line 16
+         importx unittest  # noqa: E999
+                        ^
+-    SyntaxError: invalid syntax
++    SyntaxError: invalid syntax...
+     <BLANKLINE>
+     id=sample2.badsyntax status=fail tags=(zope:import_error)
+     id=sample2.sample21.sampletests_i status=inprogress
+diff --git a/src/zope/testrunner/tests/testrunner-subunit.rst b/src/zope/testrunner/tests/testrunner-subunit.rst
+index 6597a88..1882671 100644
+--- a/src/zope/testrunner/tests/testrunner-subunit.rst
++++ b/src/zope/testrunner/tests/testrunner-subunit.rst
+@@ -480,7 +480,7 @@ Let's run tests including a module with some bad syntax:
+       File "/home/benji/workspace/all-the-trunks/zope.testrunner/src/zope/testrunner/testrunner-ex/sample2/badsyntax.py", line 16
+         importx unittest  # noqa: E999
+                        ^
+-    SyntaxError: invalid syntax
++    SyntaxError: invalid syntax...
+     ]
+     test: sample2.sample21.sampletests_i
+     tags: zope:import_error

diff --git a/dev-python/zope-testrunner/zope-testrunner-5.3.0.ebuild b/dev-python/zope-testrunner/zope-testrunner-5.3.0.ebuild
index 07f992c4b75..1142107a76c 100644
--- a/dev-python/zope-testrunner/zope-testrunner-5.3.0.ebuild
+++ b/dev-python/zope-testrunner/zope-testrunner-5.3.0.ebuild
@@ -4,7 +4,7 @@
 EAPI=7
 
 DISTUTILS_USE_SETUPTOOLS=rdepend
-PYTHON_COMPAT=( python3_{7..9} pypy3 )
+PYTHON_COMPAT=( python3_{7..10} pypy3 )
 
 inherit distutils-r1
 
@@ -20,13 +20,17 @@ LICENSE="ZPL"
 SLOT="0"
 KEYWORDS="~amd64 ~arm ~arm64 ~ppc64 ~x86"
 
-BDEPEND="
-	test? ( dev-python/zope-testing[${PYTHON_USEDEP}] )"
 RDEPEND="
 	dev-python/namespace-zope[${PYTHON_USEDEP}]
 	dev-python/six[${PYTHON_USEDEP}]
 	dev-python/zope-exceptions[${PYTHON_USEDEP}]
 	dev-python/zope-interface[${PYTHON_USEDEP}]"
+BDEPEND="
+	test? ( dev-python/zope-testing[${PYTHON_USEDEP}] )"
+
+PATCHES=(
+	"${FILESDIR}/${P}-fix-test-py3.10.patch"
+)
 
 distutils_enable_tests setup.py
 


                 reply	other threads:[~2021-05-31 12:09 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

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=1622461615.2990366dbf3fe43fba228ef3d3701cd4b453346c.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