commit: 04c867d592a9e070c4cc9888d833212d21af323a
Author: Michał Górny <mgorny <AT> gentoo <DOT> org>
AuthorDate: Wed Feb 23 22:14:12 2022 +0000
Commit: Michał Górny <mgorny <AT> gentoo <DOT> org>
CommitDate: Wed Feb 23 22:14:45 2022 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=04c867d5
app-admin/awscli: Use pytest-xdist to speed tests up
Signed-off-by: Michał Górny <mgorny <AT> gentoo.org>
app-admin/awscli/awscli-1.22.61.ebuild | 10 ++++++++--
1 file changed, 8 insertions(+), 2 deletions(-)
diff --git a/app-admin/awscli/awscli-1.22.61.ebuild
b/app-admin/awscli/awscli-1.22.61.ebuild
index 2fb60d145aa8..21a285d18863 100644
--- a/app-admin/awscli/awscli-1.22.61.ebuild
+++ b/app-admin/awscli/awscli-1.22.61.ebuild
@@ -5,7 +5,7 @@ EAPI=8
DISTUTILS_USE_PEP517=setuptools
PYTHON_COMPAT=( python3_{8..10} )
-inherit bash-completion-r1 distutils-r1
+inherit bash-completion-r1 distutils-r1 multiprocessing
DESCRIPTION="Universal Command Line Environment for AWS"
HOMEPAGE="https://pypi.org/project/awscli/"
@@ -28,6 +28,11 @@ RDEPEND="
>=dev-python/s3transfer-0.4.0[${PYTHON_USEDEP}]
dev-python/pyyaml[${PYTHON_USEDEP}]
"
+BDEPEND="
+ test? (
+ dev-python/pytest-xdist[${PYTHON_USEDEP}]
+ )
+"
distutils_enable_tests pytest
@@ -44,7 +49,8 @@ src_prepare() {
python_test() {
# integration tests require AWS credentials and Internet access
- epytest tests/{functional,unit}
+ epytest tests/{functional,unit} \
+ -n "$(makeopts_jobs "${MAKEOPTS}" "$(get_nproc)")"
}
python_install_all() {