dev-python/coverage-4.5.4: Add py38, fix tests on python2_7

Copyright: Sony Interactive Entertainment Inc.
Package-Manager: Portage-2.3.79, Repoman-2.3.18
Signed-off-by: Patrick McLean <chutzpah@gentoo.org>
This commit is contained in:
Patrick McLean
2019-11-25 18:17:45 -08:00
committed by Patrick McLean
parent f810aedb6d
commit 18ace7a077
2 changed files with 24 additions and 4 deletions

View File

@@ -2,7 +2,7 @@
# Distributed under the terms of the GNU General Public License v2
EAPI=7
PYTHON_COMPAT=( python2_7 python3_{5,6,7} pypy pypy3 )
PYTHON_COMPAT=( python{2_7,3_{5,6,7,8}} pypy{,3} )
PYTHON_REQ_USE="threads(+)"
inherit distutils-r1

View File

@@ -15,7 +15,7 @@ index 0370cf84..4e3cf1ca 100644
clean("out_timid")
diff --git a/tests/test_concurrency.py b/tests/test_concurrency.py
index 578cc679..ae340099 100644
index 578cc679..c875be86 100644
--- a/tests/test_concurrency.py
+++ b/tests/test_concurrency.py
@@ -11,6 +11,7 @@ import time
@@ -26,7 +26,27 @@ index 578cc679..ae340099 100644
import coverage
from coverage import env
from coverage.backward import import_local_file
@@ -271,6 +272,7 @@ class ConcurrencyTest(CoverageTest):
@@ -255,22 +256,27 @@ class ConcurrencyTest(CoverageTest):
code = SIMPLE.format(QLIMIT=self.QLIMIT)
self.try_some_code(code, "thread", threading)
+ @unittest.skipIf(env.PY2, "eventlet tests don't work with python tracer on python2")
def test_eventlet(self):
code = (EVENTLET + SUM_RANGE_Q + PRINT_SUM_RANGE).format(QLIMIT=self.QLIMIT)
self.try_some_code(code, "eventlet", eventlet)
+ @unittest.skipIf(env.PY2, "eventlet tests don't work with python tracer on python2")
def test_eventlet_simple_code(self):
code = SIMPLE.format(QLIMIT=self.QLIMIT)
self.try_some_code(code, "eventlet", eventlet)
+ @unittest.skipIf(env.PY2, "gevent tests don't work with python tracer on python2")
def test_gevent(self):
code = (GEVENT + SUM_RANGE_Q + PRINT_SUM_RANGE).format(QLIMIT=self.QLIMIT)
self.try_some_code(code, "gevent", gevent)
+ @unittest.skipIf(env.PY2, "gevent tests don't work with python tracer on python2")
def test_gevent_simple_code(self):
code = SIMPLE.format(QLIMIT=self.QLIMIT)
self.try_some_code(code, "gevent", gevent)
@@ -34,7 +54,7 @@ index 578cc679..ae340099 100644
def test_greenlet(self):
GREENLET = """\
from greenlet import greenlet
@@ -289,6 +291,7 @@ class ConcurrencyTest(CoverageTest):
@@ -289,6 +295,7 @@ class ConcurrencyTest(CoverageTest):
"""
self.try_some_code(GREENLET, "greenlet", greenlet, "hello world\n42\n")