75a8cca943f7f888e2f9428da7c1fd7c25a524ea
[gentoo.git] / dev-python / ansimarkup / ansimarkup-1.4.0.ebuild
1 # Copyright 1999-2019 Gentoo Authors
2 # Distributed under the terms of the GNU General Public License v2
3
4 EAPI=7
5
6 PYTHON_COMPAT=( python3_{5,6,7} )
7 inherit distutils-r1
8
9 DESCRIPTION="XML-like markup for producing colored terminal text"
10 HOMEPAGE="https://github.com/gvalkov/python-ansimarkup"
11 SRC_URI="https://github.com/gvalkov/python-${PN}/archive/v${PV}.tar.gz -> ${P}.tar.gz"
12
13 LICENSE="BSD"
14 SLOT="0"
15 KEYWORDS="~amd64 ~x86"
16 IUSE="test"
17 RESTRICT="!test? ( test )"
18
19 RDEPEND="
20         dev-python/colorama[${PYTHON_USEDEP}]
21 "
22 DEPEND="
23         dev-python/setuptools[${PYTHON_USEDEP}]
24         test? (
25                 ${RDEPEND}
26                 >=dev-python/pytest-3.0.3[${PYTHON_USEDEP}]
27         )
28 "
29
30 S="${WORKDIR}/python-${P}"
31
32 python_test() {
33         pytest -v || die "Tests failed with ${EPYTHON}"
34 }