1 # Copyright 1999-2020 Gentoo Authors
2 # Distributed under the terms of the GNU General Public License v2
6 DISTUTILS_USE_SETUPTOOLS=rdepend
7 PYTHON_COMPAT=( python{2_7,3_{6,7,8,9}} pypy3 )
11 DESCRIPTION="A goodie-bag of unix shell and environment tools for py.test"
12 HOMEPAGE="https://github.com/man-group/pytest-plugins https://pypi.org/project/pytest-shutil/"
13 SRC_URI="mirror://pypi/${P:0:1}/${PN}/${P}.tar.gz"
17 KEYWORDS="~alpha ~amd64 ~arm64 ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sparc ~x86"
19 RESTRICT="!test? ( test )"
22 dev-python/pytest[${PYTHON_USEDEP}]
23 dev-python/six[${PYTHON_USEDEP}]
24 dev-python/contextlib2[${PYTHON_USEDEP}]
25 dev-python/execnet[${PYTHON_USEDEP}]
26 dev-python/path-py[${PYTHON_USEDEP}]
27 dev-python/mock[${PYTHON_USEDEP}]
28 dev-python/termcolor[${PYTHON_USEDEP}]
33 dev-python/setuptools-git[${PYTHON_USEDEP}]
36 python_prepare_all() {
37 # keeps trying to install this in tests
38 sed -i 's:path.py::' setup.py || die
40 distutils-r1_python_prepare_all
44 # at this point let's not fix python2 stuff
45 if ! python_is_python3; then
46 ewarn "Tests broken on python2, not runninge tests for ${EPYTHON}"
50 distutils_install_for_testing
52 esetup.py test || die "Tests failed under ${EPYTHON}"