diff options
author | V3n3RiX <venerix@redcorelinux.org> | 2020-08-25 10:45:55 +0100 |
---|---|---|
committer | V3n3RiX <venerix@redcorelinux.org> | 2020-08-25 10:45:55 +0100 |
commit | 3cf7c3ef441822c889356fd1812ebf2944a59851 (patch) | |
tree | c513fe68548b40365c1c2ebfe35c58ad431cdd77 /app-text/pytextile/pytextile-4.0.1.ebuild | |
parent | 05b8b0e0af1d72e51a3ee61522941bf7605cd01c (diff) |
gentoo resync : 25.08.2020
Diffstat (limited to 'app-text/pytextile/pytextile-4.0.1.ebuild')
-rw-r--r-- | app-text/pytextile/pytextile-4.0.1.ebuild | 55 |
1 files changed, 55 insertions, 0 deletions
diff --git a/app-text/pytextile/pytextile-4.0.1.ebuild b/app-text/pytextile/pytextile-4.0.1.ebuild new file mode 100644 index 000000000000..1d920065c305 --- /dev/null +++ b/app-text/pytextile/pytextile-4.0.1.ebuild @@ -0,0 +1,55 @@ +# Copyright 1999-2020 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=7 +PYTHON_COMPAT=( python3_{7,8,9} ) +DISTUTILS_USE_SETUPTOOLS=rdepend + +inherit distutils-r1 + +MY_PN="python-textile" +MY_P="${MY_PN}-${PV}" + +DESCRIPTION="A Python port of Textile, A humane web text generator" +HOMEPAGE="https://github.com/textile/python-textile" +SRC_URI="https://github.com/textile/python-textile/archive/${PV}.tar.gz -> ${P}.tar.gz" + +LICENSE="BSD" +SLOT="0" +KEYWORDS="amd64 ~ppc ~ppc64 sparc x86" +IUSE="test" +RESTRICT="!test? ( test )" + +RDEPEND=" + dev-python/html5lib[${PYTHON_USEDEP}] + dev-python/regex[${PYTHON_USEDEP}] + dev-python/six[${PYTHON_USEDEP}]" +DEPEND=" + test? ( + ${RDEPEND} + dev-python/pytest[${PYTHON_USEDEP}] + )" + +S="${WORKDIR}/${MY_P}" + +src_prepare() { + default + # remove useless --cov arg injection + rm pytest.ini || die + # remove useless pytest-runner dep + sed -e "s/pytest-runner//g" -i setup.py || die + + # remove tests that need network access + local my_drop_tests=( + test_getimagesize.py + test_imagesize.py + test_textile.py + ) + for test in ${my_drop_tests[@]}; + do rm "tests/$test" || die + done +} + +python_test() { + pytest || die "Testsuite failed under ${EPYTHON}" +} |