edaf342667d6735ddac0877cb0d532c7d831b945
[gentoo.git] / dev-python / cli_helpers / cli_helpers-9999.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=( python{2_7,3_{5,6,7}} )
7 EGIT_REPO_URI="https://github.com/dbcli/${PN}.git"
8 inherit distutils-r1 git-r3
9
10 DESCRIPTION="Python helpers for common CLI tasks"
11 HOMEPAGE="http://cli-helpers.rtfd.io/"
12 SRC_URI=""
13
14 LICENSE="BSD"
15 SLOT="0"
16 KEYWORDS=""
17 IUSE=""
18 IUSE="test"
19 RESTRICT="!test? ( test )"
20
21 RDEPEND="
22         $(python_gen_cond_dep '>=dev-python/backports-csv-1.0[${PYTHON_USEDEP}]' -2)
23         >=dev-python/configobj-5.0.5[${PYTHON_USEDEP}]
24         >=dev-python/pygments-2.4.0[${PYTHON_USEDEP}]
25         >=dev-python/tabulate-0.8.0[${PYTHON_USEDEP}]
26         >=dev-python/terminaltables-3.0.0[${PYTHON_USEDEP}]
27         dev-python/wcwidth[${PYTHON_USEDEP}]
28 "
29 DEPEND="dev-python/setuptools[${PYTHON_USEDEP}]
30         test? (
31                 ${RDEPEND}
32                 >=dev-python/mock-2[${PYTHON_USEDEP}]
33                 dev-python/pytest[${PYTHON_USEDEP}]
34         )"
35
36 python_test() {
37         pytest -vv || die "Tests fail with ${EPYTHON}"
38 }