commit: e1eb1d05c8b13107b6ab83f3c104250b7418c6b4 Author: Marek Szuba <marecki <AT> gentoo <DOT> org> AuthorDate: Fri Feb 24 20:41:35 2023 +0000 Commit: Marek Szuba <marecki <AT> gentoo <DOT> org> CommitDate: Fri Feb 24 21:19:28 2023 +0000 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=e1eb1d05
dev-python/pytest-testinfra: enable py3.11 ...with one test disabled for that version because it depends on app-admin/salt having 3.11 support as well - and if adding 3.10 support in it was anything to go by, it will take a while. Signed-off-by: Marek Szuba <marecki <AT> gentoo.org> .../pytest-testinfra/pytest-testinfra-7.0.0.ebuild | 19 +++++++++++++++++-- 1 file changed, 17 insertions(+), 2 deletions(-) diff --git a/dev-python/pytest-testinfra/pytest-testinfra-7.0.0.ebuild b/dev-python/pytest-testinfra/pytest-testinfra-7.0.0.ebuild index 8969cefa4304..6e95a5f30b3f 100644 --- a/dev-python/pytest-testinfra/pytest-testinfra-7.0.0.ebuild +++ b/dev-python/pytest-testinfra/pytest-testinfra-7.0.0.ebuild @@ -4,7 +4,7 @@ EAPI=8 DISTUTILS_USE_PEP517=setuptools -PYTHON_COMPAT=( python3_10 ) +PYTHON_COMPAT=( python3_{10..11} ) inherit distutils-r1 @@ -30,7 +30,9 @@ BDEPEND=" dev-python/setuptools_scm[${PYTHON_USEDEP}] test? ( app-admin/ansible - app-admin/salt[${PYTHON_USEDEP}] + $(python_gen_cond_dep ' + app-admin/salt[${PYTHON_USEDEP}] + ' python3_10) dev-python/paramiko[${PYTHON_USEDEP}] dev-python/pywinrm[${PYTHON_USEDEP}] sys-apps/which @@ -39,6 +41,19 @@ BDEPEND=" distutils_enable_tests pytest +python_test() { + local -x EPYTEST_IGNORE=() + + # This is the only test which actually fails if salt cannot be imported + if [[ ${EPYTHON} == python3.11 ]]; then + EPYTEST_IGNORE+=( + test/test_backends.py::test_backend_importables + ) + fi + + epytest +} + pkg_postinst() { elog "For the list of available connection back-ends and their dependencies," elog "please consult https://testinfra.readthedocs.io/en/latest/backends.html"