Gentoo Archives: gentoo-commits

From: "Michał Górny" <mgorny@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: dev-python/pyhamcrest/
Date: Mon, 16 Jul 2018 14:06:02
Message-Id: 1531749952.0fae70a0880d2a182fe3544cd904e56e702a7484.mgorny@gentoo
1 commit: 0fae70a0880d2a182fe3544cd904e56e702a7484
2 Author: Michał Górny <mgorny <AT> gentoo <DOT> org>
3 AuthorDate: Mon Jul 16 14:03:32 2018 +0000
4 Commit: Michał Górny <mgorny <AT> gentoo <DOT> org>
5 CommitDate: Mon Jul 16 14:05:52 2018 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=0fae70a0
7
8 dev-python/pyhamcrest: Enable tests
9
10 dev-python/pyhamcrest/Manifest | 1 +
11 dev-python/pyhamcrest/pyhamcrest-1.9.0-r1.ebuild | 54 ++++++++++++++++++++++++
12 2 files changed, 55 insertions(+)
13
14 diff --git a/dev-python/pyhamcrest/Manifest b/dev-python/pyhamcrest/Manifest
15 index d52753b709c..2b62afa078c 100644
16 --- a/dev-python/pyhamcrest/Manifest
17 +++ b/dev-python/pyhamcrest/Manifest
18 @@ -1 +1,2 @@
19 +DIST PyHamcrest-1.9.0.gh.tar.gz 57650 BLAKE2B c497688f03ec3b072d8ab076fc096a442d5cbbd94493eae57779879ccb6f281477aeeb7f7a67e539442010e60194f9f04a6deddd1d2267e9743742b45433f124 SHA512 3a878637ed5138365416c170871a63640f089047b723c7ec8db893dd716c0b1cdad16a98584700405693b954af7d4868a8543d1a3fc58ded22b493c8c61661b4
20 DIST PyHamcrest-1.9.0.tar.gz 376623 BLAKE2B 808c74aa4dff89467c126cbc0e18029a9504cb27bbf03662a90666f85c76d7d7617260f50d35acde3a8e9e437b846589423cbb3697f8ceb86d0b5b838c586ebd SHA512 3b8393d0079b619b208ec7f06ed5133c4ff9d9dba050f818adf56347fc2225fd1c85d60f3dc262b7b9722061f0b8e4966180b6b96245a371e578d0d51633b4b0
21
22 diff --git a/dev-python/pyhamcrest/pyhamcrest-1.9.0-r1.ebuild b/dev-python/pyhamcrest/pyhamcrest-1.9.0-r1.ebuild
23 new file mode 100644
24 index 00000000000..4149b8e2ad3
25 --- /dev/null
26 +++ b/dev-python/pyhamcrest/pyhamcrest-1.9.0-r1.ebuild
27 @@ -0,0 +1,54 @@
28 +# Copyright 1999-2018 Gentoo Foundation
29 +# Distributed under the terms of the GNU General Public License v2
30 +
31 +EAPI=6
32 +PYTHON_COMPAT=( python2_7 python3_{4,5,6} )
33 +
34 +inherit distutils-r1
35 +
36 +MY_PN="PyHamcrest"
37 +
38 +DESCRIPTION="Hamcrest framework for matcher objects"
39 +HOMEPAGE="https://github.com/hamcrest/PyHamcrest"
40 +SRC_URI="https://github.com/hamcrest/PyHamcrest/archive/V${PV}.tar.gz -> ${MY_PN}-${PV}.gh.tar.gz"
41 +
42 +LICENSE="BSD"
43 +SLOT="0"
44 +KEYWORDS="~amd64"
45 +IUSE="doc examples test"
46 +
47 +RDEPEND=">=dev-python/six-1.4[${PYTHON_USEDEP}]"
48 +DEPEND="${RDEPEND}
49 + dev-python/setuptools[${PYTHON_USEDEP}]
50 + doc? (
51 + >=dev-python/sphinx-1.2.2[${PYTHON_USEDEP}]
52 + dev-python/sphinx_rtd_theme[${PYTHON_USEDEP}]
53 + )
54 + test? (
55 + >=dev-python/pytest-2.6[${PYTHON_USEDEP}]
56 + dev-python/mock[${PYTHON_USEDEP}]
57 + )"
58 +
59 +S="${WORKDIR}/${MY_PN}-${PV}"
60 +
61 +python_prepare_all() {
62 + # enables coverage testing which we don't want
63 + rm pytest.ini || die
64 + distutils-r1_python_prepare_all
65 +}
66 +
67 +python_compile_all() {
68 + use doc && esetup.py build_sphinx
69 +}
70 +
71 +python_test() {
72 + py.test -vv || die "Tests failed under ${EPYTHON}"
73 + "${PYTHON}" tests/object_import.py || die "Tests failed under ${EPYTHON}"
74 +}
75 +
76 +python_install_all() {
77 + use doc && local HTML_DOCS=( doc/_build/html/. )
78 + use examples && dodoc -r examples
79 +
80 + distutils-r1_python_install_all
81 +}