summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorArthur Zamarin <arthurzam@gentoo.org>2021-11-11 11:09:40 +0200
committerArthur Zamarin <arthurzam@gentoo.org>2021-11-11 11:12:38 +0200
commit2e11d6bfd44b11613e98b9abd75b60b25037354d (patch)
tree3d28a178bc7a3365b4d77601846910a755bf46fa
parentdev-java/icu4j: remove unused slot 56 (diff)
downloadgentoo-2e11d6bfd44b11613e98b9abd75b60b25037354d.tar.gz
gentoo-2e11d6bfd44b11613e98b9abd75b60b25037354d.tar.bz2
gentoo-2e11d6bfd44b11613e98b9abd75b60b25037354d.zip
dev-python/nose: add 1.3.7_p20211111
As upstream is very dead, and nose is deprecated, we at Gentoo still need it for many test suites. This is very useful package for us. Therefore I forked it, and started fixing it to be useful again: apply 2to3 everywhere, fix multiple tests, apply all out patches, add new tests markers. Closes: https://bugs.gentoo.org/812500 Signed-off-by: Arthur Zamarin <arthurzam@gentoo.org>
-rw-r--r--dev-python/nose/Manifest1
-rw-r--r--dev-python/nose/nose-1.3.7_p20211111.ebuild54
2 files changed, 55 insertions, 0 deletions
diff --git a/dev-python/nose/Manifest b/dev-python/nose/Manifest
index ea56763f9479..344725536837 100644
--- a/dev-python/nose/Manifest
+++ b/dev-python/nose/Manifest
@@ -1 +1,2 @@
DIST nose-1.3.7.tar.gz 280488 BLAKE2B 4bb479b2786f813f9e9a5fd401e30023a473a053ae013d7887be15af415422c09fb399af6058ae99ed65c5fa4da84eb274eb805e895ca74db159d952905f5be4 SHA512 e65c914f621f8da06b9ab11a0ff2763d6e29b82ce2aaed56da0e3773dc899d9deb1f20015789d44c65a5dad7214520f5b659b3f8d7695fb207ad3f78e5cf1b62
+DIST nose-1.3.7_p20211111.gh.tar.gz 327877 BLAKE2B a284275a9fdd74ebffaa425cb89735a8655f9db74e6503ebd9c0420e77006828de1f8383f9c4b4828489208ae8959aa0bd5a75f5a474b61e213e915c5c61b611 SHA512 913a536ce4aba377627a050e7fd8fa5cea843b66bf5da2778d7ce7c26e9485361d60ee09767da721813978576f6ead1219ddafffecc2955a33a0df6d2d44a48c
diff --git a/dev-python/nose/nose-1.3.7_p20211111.ebuild b/dev-python/nose/nose-1.3.7_p20211111.ebuild
new file mode 100644
index 000000000000..2af3c30e088b
--- /dev/null
+++ b/dev-python/nose/nose-1.3.7_p20211111.ebuild
@@ -0,0 +1,54 @@
+# Copyright 1999-2021 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+
+PYTHON_COMPAT=( python3_{8..10} pypy3 )
+PYTHON_REQ_USE="threads(+)"
+inherit distutils-r1
+
+COMMIT="a4a1710cf5a71bde82951f2ef96a6837124b74af"
+
+DESCRIPTION="Unittest extension with automatic test suite discovery and easy test authoring"
+HOMEPAGE="
+ https://pypi.org/project/nose/
+ https://nose.readthedocs.io/en/latest/
+ https://github.com/nose-devs/nose"
+SRC_URI="
+ https://github.com/arthurzam/nose/archive/${COMMIT}.tar.gz
+ -> ${P}.gh.tar.gz
+"
+S="${WORKDIR}/${PN}-${COMMIT}"
+
+LICENSE="LGPL-2.1"
+SLOT="0"
+KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris"
+IUSE="examples test"
+RESTRICT="!test? ( test )"
+
+BDEPEND="
+ test? (
+ $(python_gen_cond_dep '
+ !hppa? ( dev-python/coverage[${PYTHON_USEDEP}] )
+ ' python3_{8..10} pypy3)
+ $(python_gen_cond_dep '
+ dev-python/twisted[${PYTHON_USEDEP}]
+ ' python3_{8..10})
+ )"
+
+src_prepare() {
+ # failing to find configuration file
+ sed -e 's/test_cover_options_config_file/_&/' \
+ -i unit_tests/test_cover_plugin.py || die
+
+ distutils-r1_src_prepare
+}
+
+python_test() {
+ "${EPYTHON}" -m nose -v -a "!network" || die "Tests fail with ${EPYTHON}"
+}
+
+src_install() {
+ distutils-r1_src_install
+ use examples && dodoc -r examples
+}