From 6a90f068429b9eb509feb7f7150f4d9a792c5b8b Mon Sep 17 00:00:00 2001 From: Sergey Torokhov Date: Thu, 1 Dec 2022 21:30:53 +0300 Subject: [PATCH] dev-util/fortls: Fix and enable tests Signed-off-by: Sergey Torokhov --- dev-util/fortls/fortls-2.13.0.ebuild | 20 ++++++++++++++++---- 1 file changed, 16 insertions(+), 4 deletions(-) diff --git a/dev-util/fortls/fortls-2.13.0.ebuild b/dev-util/fortls/fortls-2.13.0.ebuild index 434a2400cf..648fdff35d 100644 --- a/dev-util/fortls/fortls-2.13.0.ebuild +++ b/dev-util/fortls/fortls-2.13.0.ebuild @@ -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 +}