commit: 143550df19c36e5906c8661a57cb0089e7b146af Author: Anna Vyalkova <cyber <AT> sysrq <DOT> in> AuthorDate: Mon May 3 21:54:39 2021 +0000 Commit: Anna Vyalkova <cyber+gentoo <AT> sysrq <DOT> in> CommitDate: Mon May 3 23:27:25 2021 +0000 URL: https://gitweb.gentoo.org/repo/proj/guru.git/commit/?id=143550df
dev-python/hunter: fix tests and bump to 3.3.2 Dropped 3.1.3 because there's no way I'm messing with tests in another one version! >.< Closes: https://bugs.gentoo.org/787050 Signed-off-by: Anna Vyalkova <cyber <AT> sysrq.in> dev-python/hunter/Manifest | 3 +- dev-python/hunter/hunter-3.1.3.ebuild | 51 ---------------------- .../{hunter-3.3.1.ebuild => hunter-3.3.2.ebuild} | 23 +++++++++- 3 files changed, 23 insertions(+), 54 deletions(-) diff --git a/dev-python/hunter/Manifest b/dev-python/hunter/Manifest index a814d24eb..4766d81ce 100644 --- a/dev-python/hunter/Manifest +++ b/dev-python/hunter/Manifest @@ -1,2 +1 @@ -DIST hunter-3.1.3.tar.gz 422149 BLAKE2B 2834b3daa6be461b78d468aa331a587a476b7109f5ff9c70b27bb51b26f6a390d2074425f4d98ddc692d4e11f1ee14a77f5066650e82687ebaa586051afab4c8 SHA512 ea9cc935240526d2942568073cecfb2bef32d7caedd0b370850b208a56c652bf356ba0e5675281946419aafd966cbff148490f6f4439d0d808335a3e831adbf7 -DIST hunter-3.3.1.tar.gz 533218 BLAKE2B 9ad62c4c5649b3389a480732a3f6939f54fe39f25362e5f796d78ab8286d6aada326035882d81a09c985765c4acc6283e1bd6665c473ca3edb9a84a6f2b301e6 SHA512 8ac5d2f993bc7c75adae532d4bff5a905c7ec84d32389fcfabb4c5ca3d511a73dc84725d5a450be7d1281e006ec049a5b43c01a79890e0b00302b6b7df291d55 +DIST hunter-3.3.2.tar.gz 535119 BLAKE2B 25551f04d0b2dafa6875c5c5660d2c57417bdc113960ec2b8d224c88a6b9d08b38bfbbb2deb516e7a36704164318137f5675409850c2eeff2c486a819731c756 SHA512 e3b5e7a3729074cf52a7a209e6f54a1319b3e94ff50abe4e6d8f00f3953720e3c2380de066c2a0a4e56c7a348fdd947425ae19c8907bd420d10ffb271bc07516 diff --git a/dev-python/hunter/hunter-3.1.3.ebuild b/dev-python/hunter/hunter-3.1.3.ebuild deleted file mode 100644 index 86af50715..000000000 --- a/dev-python/hunter/hunter-3.1.3.ebuild +++ /dev/null @@ -1,51 +0,0 @@ -# Copyright 1999-2020 Gentoo Authors -# Distributed under the terms of the GNU General Public License v2 - -EAPI=7 - -PYTHON_COMPAT=( python3_{7,8} ) - -DISTUTILS_USE_SETUPTOOLS=rdepend - -inherit distutils-r1 - -DESCRIPTION="Hunter is a flexible code tracing toolkit" -HOMEPAGE=" - https://github.com/ionelmc/python-hunter - https://pypi.org/project/hunter -" -SRC_URI="https://github.com/ionelmc/python-${PN}/archive/v${PV}.tar.gz -> ${P}.tar.gz" - -LICENSE="BSD-2" -SLOT="0" -KEYWORDS="~amd64 ~x86" - -RDEPEND=" - dev-python/colorama[${PYTHON_USEDEP}] -" -DEPEND=" - ${RDEPEND} - test? ( - dev-python/aspectlib[${PYTHON_USEDEP}] - dev-python/hunter[${PYTHON_USEDEP}] - dev-python/manhole[${PYTHON_USEDEP}] - dev-python/pytest-benchmark[${PYTHON_USEDEP}] - dev-python/process-tests[${PYTHON_USEDEP}] - ) -" -BDEPEND=" - dev-python/cython[${PYTHON_USEDEP}] - >=dev-python/setuptools_scm-3.3.1[${PYTHON_USEDEP}] -" - -S="${WORKDIR}/python-${P}" - -distutils_enable_tests pytest -distutils_enable_sphinx docs ">=dev-python/sphinx-py3doc-enhanced-theme-2.3.2" - -python_prepare_all() { - # all tests in this file fail - rm tests/test_remote.py || die - - distutils-r1_python_prepare_all -} diff --git a/dev-python/hunter/hunter-3.3.1.ebuild b/dev-python/hunter/hunter-3.3.2.ebuild similarity index 59% rename from dev-python/hunter/hunter-3.3.1.ebuild rename to dev-python/hunter/hunter-3.3.2.ebuild index 952cd2f05..51a71d901 100644 --- a/dev-python/hunter/hunter-3.3.1.ebuild +++ b/dev-python/hunter/hunter-3.3.2.ebuild @@ -25,7 +25,6 @@ DEPEND=" ${RDEPEND} test? ( dev-python/aspectlib[${PYTHON_USEDEP}] - dev-python/hunter[${PYTHON_USEDEP}] dev-python/manhole[${PYTHON_USEDEP}] dev-python/pytest-benchmark[${PYTHON_USEDEP}] dev-python/process-tests[${PYTHON_USEDEP}] @@ -45,5 +44,27 @@ python_prepare_all() { # all tests in this file fail rm tests/test_remote.py || die + sed 's/setuptools_scm>=3.3.1,!=4.0.0,<6.0/setuptools_scm>=3.3.1/' \ + -i setup.py || die + distutils-r1_python_prepare_all } + +python_compile() { + distutils-r1_python_compile + + if use test; then + "${EPYTHON}" tests/setup.py build_ext --force --inplace || die + fi +} + +python_test() { + local -x PYTHONPATH="${S}/tests:${BUILD_DIR}/lib:${PYTHONPATH}" + epytest --ignore=src \ + --deselect tests/test_integration.py::test_pth_activation \ + --deselect tests/test_integration.py::test_pth_sample4 \ + --deselect tests/test_integration.py::test_pth_sample2 \ + --deselect tests/test_integration.py::test_depth_limit_subprocess[depth_lt=2] \ + --deselect tests/test_integration.py::test_depth_limit_subprocess[depth_lt=3] \ + --deselect tests/test_integration.py::test_depth_limit_subprocess[depth_lt=4] +}
