diff options
author | Ali Polatel <hawking@gentoo.org> | 2007-09-14 09:24:15 +0000 |
---|---|---|
committer | Ali Polatel <hawking@gentoo.org> | 2007-09-14 09:24:15 +0000 |
commit | be06bacd5f2f09bbd623f874ddcdf2b3a80ce1cc (patch) | |
tree | 6e1db52a4e1fcb869a982b4393b4d89ed8a9fcd6 /dev-python | |
parent | Require latest versions of some input drivers for compat with the new input s... (diff) | |
download | gentoo-2-be06bacd5f2f09bbd623f874ddcdf2b3a80ce1cc.tar.gz gentoo-2-be06bacd5f2f09bbd623f874ddcdf2b3a80ce1cc.tar.bz2 gentoo-2-be06bacd5f2f09bbd623f874ddcdf2b3a80ce1cc.zip |
Version bump, added twisted use flag and made nose.twistedtools and twisted tests conditional (thanks to Dirkjan Ochtman - bug 187780 )
(Portage version: 2.1.3.9)
Diffstat (limited to 'dev-python')
-rw-r--r-- | dev-python/nose/ChangeLog | 9 | ||||
-rw-r--r-- | dev-python/nose/files/digest-nose-0.10.0_beta1 | 3 | ||||
-rw-r--r-- | dev-python/nose/files/nose-tests-nonetwork.patch | 34 | ||||
-rw-r--r-- | dev-python/nose/nose-0.10.0_beta1.ebuild | 57 |
4 files changed, 102 insertions, 1 deletions
diff --git a/dev-python/nose/ChangeLog b/dev-python/nose/ChangeLog index 70e193fba9fc..9094b5e81f84 100644 --- a/dev-python/nose/ChangeLog +++ b/dev-python/nose/ChangeLog @@ -1,6 +1,13 @@ # ChangeLog for dev-python/nose # Copyright 1999-2007 Gentoo Foundation; Distributed under the GPL v2 -# $Header: /var/cvsroot/gentoo-x86/dev-python/nose/ChangeLog,v 1.5 2007/07/31 08:21:43 dev-zero Exp $ +# $Header: /var/cvsroot/gentoo-x86/dev-python/nose/ChangeLog,v 1.6 2007/09/14 09:24:14 hawking Exp $ + +*nose-0.10.0_beta1 (14 Sep 2007) + + 14 Sep 2007; Ali Polatel <hawking@gentoo.org> + +files/nose-tests-nonetwork.patch, +nose-0.10.0_beta1.ebuild: + Version bump, added twisted use flag and made nose.twistedtools and twisted + tests conditional (thanks to Dirkjan Ochtman - bug 187780 ) *nose-0.10.0_alpha2 (31 Jul 2007) diff --git a/dev-python/nose/files/digest-nose-0.10.0_beta1 b/dev-python/nose/files/digest-nose-0.10.0_beta1 new file mode 100644 index 000000000000..e793b1075dd8 --- /dev/null +++ b/dev-python/nose/files/digest-nose-0.10.0_beta1 @@ -0,0 +1,3 @@ +MD5 f4c5c6054b26ccb3ae04f39e693c20d5 nose-0.10.0b1.tar.gz 277581 +RMD160 5cf1241e44ed46ac3ed3e012e76d325c08988bde nose-0.10.0b1.tar.gz 277581 +SHA256 c5be4c5c3c2624eb35c644ef34be3e5962cb78723a3c7c7f5731c77626f79f14 nose-0.10.0b1.tar.gz 277581 diff --git a/dev-python/nose/files/nose-tests-nonetwork.patch b/dev-python/nose/files/nose-tests-nonetwork.patch new file mode 100644 index 000000000000..d853db93ce65 --- /dev/null +++ b/dev-python/nose/files/nose-tests-nonetwork.patch @@ -0,0 +1,34 @@ +--- unit_tests/test_twisted.py.orig 2007-08-11 19:09:41.000000000 +0300 ++++ unit_tests/test_twisted.py 2007-09-14 11:30:40.000000000 +0300 +@@ -13,31 +13,6 @@ + class CustomError(Exception): + pass + +-# FIXME move all dns-using tests to functional +- +-# Should succeed unless google is down +-#@deferred +-def test_resolve(): +- return reactor.resolve("www.google.com") +-test_resolve = deferred()(test_resolve) +- +-# Raises TypeError because the function does not return a Deferred +-#@raises(TypeError) +-#@deferred() +-def test_raises_bad_return(): +- print reactor +- reactor.resolve("nose.python-hosting.com") +-test_raises_bad_return = raises(TypeError)(deferred()(test_raises_bad_return)) +- +-# Check we propagate twisted Failures as Exceptions +-# (XXX this test might take some time: find something better?) +-#@raises(DNSLookupError) +-#@deferred() +-def test_raises_twisted_error(): +- return reactor.resolve("x.y.z") +-test_raises_twisted_error = raises(DNSLookupError)( +- deferred()(test_raises_twisted_error)) +- + # Check we detect Exceptions inside the callback chain + #@raises(CustomError) + #@deferred(timeout=1.0) diff --git a/dev-python/nose/nose-0.10.0_beta1.ebuild b/dev-python/nose/nose-0.10.0_beta1.ebuild new file mode 100644 index 000000000000..8b82e8a92c0b --- /dev/null +++ b/dev-python/nose/nose-0.10.0_beta1.ebuild @@ -0,0 +1,57 @@ +# Copyright 1999-2007 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/dev-python/nose/nose-0.10.0_beta1.ebuild,v 1.1 2007/09/14 09:24:14 hawking Exp $ + +NEED_PYTHON=2.2 + +inherit distutils eutils + +MY_PV="${PV/_beta/b}" +MY_P="${PN}-${MY_PV}" +DESCRIPTION="A unittest extension offering automatic test suite discovery and easy test authoring" +HOMEPAGE="http://somethingaboutorange.com/mrl/projects/nose/" +SRC_URI="http://somethingaboutorange.com/mrl/projects/nose/${MY_P}.tar.gz" + +LICENSE="LGPL-2.1" +KEYWORDS="~amd64 ~x86" +SLOT="0" +IUSE="doc examples twisted" + +RDEPEND="dev-python/setuptools + twisted? ( dev-python/twisted )" +DEPEND="${RDEPEND} + doc? ( dev-python/docutils )" + +S="${WORKDIR}/${MY_P}" + +src_unpack() { + distutils_src_unpack + + # If twisted is in USE, disable twisted tests that access the network + # else remove nose.twistedtools and related tests + use twisted && epatch "${FILESDIR}/${PN}-tests-nonetwork.patch" + use twisted || rm nose/twistedtools.py unit_tests/test_twisted* +} + +src_compile() { + distutils_src_compile + if use doc ; then + PYTHONPATH=. scripts/mkindex.py + fi +} + +src_install() { + DOCS="AUTHORS NEWS" + distutils_src_install --install-data /usr/share + + use doc && dohtml index.html + + if use examples ; then + insinto /usr/share/doc/${PF} + doins -r examples + fi +} + +src_test() { + PYTHONPATH=. "${python}" setup.py test || die "test failed" +} |