dev-util/fortls: Fix and enable tests

Signed-off-by: Sergey Torokhov <torokhov-s-a@yandex.ru>
This commit is contained in:
Sergey Torokhov
2022-12-01 21:30:53 +03:00
parent 4dbf36ce3f
commit 6a90f06842

View File

@@ -8,7 +8,7 @@ PYTHON_COMPAT=( python3_{8..11} )
inherit distutils-r1
DESCRIPTION="fortls - Fortran Language Server"
DESCRIPTION="Fortran Language Server (fortls)"
HOMEPAGE="https://fortls.fortran-lang.org"
SRC_URI="mirror://pypi/${PN:0:1}/${PN}/${P}.tar.gz"
@@ -16,9 +16,21 @@ LICENSE="MIT"
SLOT="0"
KEYWORDS="~amd64"
# Need to explore the list of test dependencies
RESTRICT="test"
RDEPEND="
dev-python/json5[${PYTHON_USEDEP}]
"
distutils_enable_tests pytest
EPYTEST_DESELECT=(
test/test_interface.py::test_version_update_pypi
)
src_prepare() {
# Drop some additional coverage tests
sed -i -e 's/ --cov=fortls --cov-report=html --cov-report=xml --cov-context=test//' pyproject.toml || die
# Disable autoupdate check during tests run
sed -i -e 's/"--incremental_sync",/"--incremental_sync", "--disable_autoupdate",/' test/setup_tests.py || die
distutils-r1_src_prepare
}