Files
guru/dev-python/rstcheck/rstcheck-6.2.0.ebuild
T

36 lines
928 B
Bash
Raw Normal View History

# Copyright 1999-2023 Gentoo Authors
2020-06-26 22:31:15 +01:00
# Distributed under the terms of the GNU General Public License v2
EAPI=8
2020-06-26 22:31:15 +01:00
DISTUTILS_USE_PEP517=poetry
2023-10-18 05:36:05 +01:00
PYTHON_COMPAT=( python3_{10..12} )
2020-06-26 22:31:15 +01:00
2023-03-17 17:49:19 +05:00
inherit distutils-r1 pypi
2020-06-26 22:31:15 +01:00
DESCRIPTION="Checks syntax of reStructuredText and code blocks nested within it"
HOMEPAGE="https://github.com/rstcheck/rstcheck"
2020-06-26 22:31:15 +01:00
LICENSE="MIT"
SLOT="0"
KEYWORDS="~amd64"
RDEPEND="dev-python/docutils[${PYTHON_USEDEP}]"
2020-06-26 22:31:15 +01:00
BDEPEND="
>=dev-python/setuptools-scm-1.15.0[${PYTHON_USEDEP}]
2020-06-26 22:31:15 +01:00
test? (
${RDEPEND}
dev-python/path[${PYTHON_USEDEP}]
2020-06-26 22:31:15 +01:00
)
"
2020-06-29 21:25:23 +01:00
distutils_enable_tests pytest
2020-06-26 22:31:15 +01:00
python_test() {
# Ignore the module from ${S}, use the one from ${BUILD_DIR}
# Otherwise, ImportMismatchError may occur
# https://github.com/gentoo/gentoo/pull/1622#issuecomment-224482396
# Override pytest options to skip flake8
pytest -vv --ignore=rst --override-ini="addopts=--doctest-modules" \
|| die "tests failed with ${EPYTHON}"
}