dev-python/testrepository: Depend on threading support in python
[gentoo.git] / dev-python / testrepository / testrepository-0.0.20.ebuild
1 # Copyright 1999-2015 Gentoo Foundation
2 # Distributed under the terms of the GNU General Public License v2
3 # $Id$
4
5 EAPI=5
6
7 PYTHON_COMPAT=( python2_7 python3_{3,4,5} pypy pypy3 )
8 PYTHON_REQ_USE="threads(+)"
9
10 inherit distutils-r1
11
12 DESCRIPTION="A repository of test results"
13 HOMEPAGE="https://launchpad.net/testscenarios"
14 SRC_URI="mirror://pypi/${PN:0:1}/${PN}/${P}.tar.gz"
15
16 LICENSE="Apache-2.0"
17 SLOT="0"
18 KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~amd64-linux ~x86-linux"
19 IUSE="test"
20
21 RDEPEND="
22         >=dev-python/subunit-0.0.18[${PYTHON_USEDEP}]
23         >=dev-python/testtools-0.9.30[${PYTHON_USEDEP}]
24         dev-python/fixtures[${PYTHON_USEDEP}]"
25 #bzr is listed but presumably req'd for a live repo test run
26
27 DEPEND="
28         dev-python/setuptools[${PYTHON_USEDEP}]
29         test? ( ${RDEPEND}
30                 dev-python/testresources[${PYTHON_USEDEP}]
31                 dev-python/testscenarios[${PYTHON_USEDEP}]
32                 dev-python/pytz[${PYTHON_USEDEP}]
33         )"
34
35 # Required for test phase
36 DISTUTILS_IN_SOURCE_BUILD=1
37
38 PATCHES=(
39         "${FILESDIR}"/${P}-test-backport.patch
40         "${FILESDIR}"/${P}-test-backport1.patch
41 )
42
43 python_test() {
44         # some errors appear to have crept in the suite undert py3 since addition.
45         # Python2.7 now passes all.
46
47         ${PYTHON} testr init || die
48         ${PYTHON} testr run || die
49 }