commit:     542628e1824726c4a1dad8ef485565ee8b50b752
Author:     David Seifert <soap <AT> gentoo <DOT> org>
AuthorDate: Fri Sep 18 09:46:34 2020 +0000
Commit:     David Seifert <soap <AT> gentoo <DOT> org>
CommitDate: Fri Sep 18 09:46:34 2020 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=542628e1

sys-apps/gcp: Add python 3.8/3.9

Package-Manager: Portage-3.0.7, Repoman-3.0.1
Signed-off-by: David Seifert <soap <AT> gentoo.org>

 sys-apps/gcp/gcp-0.2.1.ebuild | 18 ++++++++++++++----
 1 file changed, 14 insertions(+), 4 deletions(-)

diff --git a/sys-apps/gcp/gcp-0.2.1.ebuild b/sys-apps/gcp/gcp-0.2.1.ebuild
index 3425601feba..040b1f0138f 100644
--- a/sys-apps/gcp/gcp-0.2.1.ebuild
+++ b/sys-apps/gcp/gcp-0.2.1.ebuild
@@ -1,11 +1,11 @@
-# Copyright 1999-2019 Gentoo Authors
+# Copyright 1999-2020 Gentoo Authors
 # Distributed under the terms of the GNU General Public License v2
 
 EAPI=7
 
-PYTHON_COMPAT=( python3_{6,7} )
+PYTHON_COMPAT=( python3_{6..9} )
 
-inherit distutils-r1
+inherit distutils-r1 virtualx
 
 DESCRIPTION="File copying utility with progress and I/O indicator"
 HOMEPAGE="https://code.lm7.fr/mcy/gcp";
@@ -15,10 +15,20 @@ LICENSE="GPL-3"
 SLOT="0"
 KEYWORDS="~amd64 ~x86"
 
-DEPEND="dev-python/setuptools[${PYTHON_USEDEP}]"
 RDEPEND="
        dev-python/dbus-python[${PYTHON_USEDEP}]
        dev-python/progressbar[${PYTHON_USEDEP}]
        dev-python/pygobject:3[${PYTHON_USEDEP}]"
 
+distutils_enable_tests unittest
+
 PATCHES=( "${FILESDIR}"/${PN}-0.2.1-gentoo-fhs.patch )
+
+src_test() {
+       virtx distutils-r1_src_test
+}
+
+python_test() {
+       local -x PATH="${S}:${PATH}"
+       "${EPYTHON}" test/test_gcp.py || die "Tests fail with ${EPYTHON}"
+}

Reply via email to