1 # Copyright 1999-2020 Gentoo Authors
2 # Distributed under the terms of the GNU General Public License v2
5 PYTHON_COMPAT=( python3_{6,7} )
9 DESCRIPTION="A JavaScript Object Signing and Encryption (JOSE) implementation in Python"
10 HOMEPAGE="https://github.com/mpdavis/python-jose https://pypi.org/project/python-jose/"
11 # pypi tarball lacks unit tests
12 #SRC_URI="mirror://pypi/${P:0:1}/${PN}/${P}.tar.gz"
13 SRC_URI="https://github.com/mpdavis/python-jose/archive/${PV}.tar.gz -> ${P}.tar.gz"
17 KEYWORDS="amd64 x86 ~amd64-linux ~x86-linux"
19 RESTRICT="!test? ( test )"
20 RDEPEND="dev-python/cryptography[${PYTHON_USEDEP}]
21 dev-python/ecdsa[${PYTHON_USEDEP}]
22 dev-python/pyasn1[${PYTHON_USEDEP}]
23 >=dev-python/pycryptodome-3.3.1[${PYTHON_USEDEP}]
24 dev-python/rsa[${PYTHON_USEDEP}]
25 dev-python/six[${PYTHON_USEDEP}]"
27 dev-python/setuptools[${PYTHON_USEDEP}]
29 dev-python/pytest[${PYTHON_USEDEP}]
30 dev-python/pytest-cov[${PYTHON_USEDEP}]
33 python_prepare_all() {
34 sed -e 's|'\''pytest-runner'\'',\?||' -i setup.py || die
35 distutils-r1_python_prepare_all
39 py.test -v || die "tests failed with ${EPYTHON}"