src_prepare-overlay/dev-python/aioresponses/aioresponses-0.7.2.ebuild

46 lines
946 B
Bash
Raw Normal View History

# Copyright 2021 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=7
PYTHON_COMPAT=( python3_{8..9} )
inherit distutils-r1
DESCRIPTION="Aioresponses is a helper for mock/fake web requests in python aiohttp package. "
HOMEPAGE="https://github.com/pnuckowski/aioresponses"
SRC_URI="mirror://pypi/${P:0:1}/${PN}/${P}.tar.gz"
LICENSE="MIT"
SLOT="0"
KEYWORDS="~amd64"
IUSE="doc"
# Tests hard depend on internet access
RESTRICT="test"
#RESTRICT="!test? ( test )"
RDEPEND="
dev-python/aiohttp[${PYTHON_USEDEP}]
"
#DEPEND="
# test? (
# ${RDEPEND}
# dev-python/ddt[${PYTHON_USEDEP}]
# dev-python/pytest-cov[${PYTHON_USEDEP}]
# )
#"
BDEPEND="
dev-python/pbr[${PYTHON_USEDEP}]
doc? ( dev-python/sphinx )
"
#distutils_enable_tests pytest
python_compile_all() {
use doc && emake -C docs -j1 html
}
python_install_all() {
use doc && HTML_DOCS=( docs/_build/html/. )
distutils-r1_python_install_all
}