diff options
author | V3n3RiX <venerix@redcorelinux.org> | 2017-10-09 18:53:29 +0100 |
---|---|---|
committer | V3n3RiX <venerix@redcorelinux.org> | 2017-10-09 18:53:29 +0100 |
commit | 4f2d7949f03e1c198bc888f2d05f421d35c57e21 (patch) | |
tree | ba5f07bf3f9d22d82e54a462313f5d244036c768 /dev-python/testtools |
reinit the tree, so we can have metadata
Diffstat (limited to 'dev-python/testtools')
-rw-r--r-- | dev-python/testtools/Manifest | 14 | ||||
-rw-r--r-- | dev-python/testtools/files/testtools-1.8.0-twisted-backport.patch | 74 | ||||
-rw-r--r-- | dev-python/testtools/files/testtools-1.8.0-twisted-backport1.patch | 33 | ||||
-rw-r--r-- | dev-python/testtools/files/testtools-1.8.0-twisted-backport2.patch | 57 | ||||
-rw-r--r-- | dev-python/testtools/metadata.xml | 17 | ||||
-rw-r--r-- | dev-python/testtools/testtools-0.9.36.ebuild | 50 | ||||
-rw-r--r-- | dev-python/testtools/testtools-1.8.0.ebuild | 52 | ||||
-rw-r--r-- | dev-python/testtools/testtools-2.2.0.ebuild | 53 | ||||
-rw-r--r-- | dev-python/testtools/testtools-2.3.0.ebuild | 53 |
9 files changed, 403 insertions, 0 deletions
diff --git a/dev-python/testtools/Manifest b/dev-python/testtools/Manifest new file mode 100644 index 000000000000..8a27712abbac --- /dev/null +++ b/dev-python/testtools/Manifest @@ -0,0 +1,14 @@ +AUX testtools-1.8.0-twisted-backport.patch 3154 SHA256 d1c8a4aefaf059b30792a920fa81a0b8690a9cdd15a9eabdc9d8359ae6f75ef8 SHA512 a21e6cfdc50620f783ae9825cc7e7deee875becd7b297b8d47cf217668330fe5a0ee4eca24d56c0fea3da020828112f0a48ae78b2c74de5b60d39325197d3c74 WHIRLPOOL 27d282c9a21b9f9c41f6c72c75321026b935ac3f66ea5bce46592082de9e8a6afe76b78d769a73e399da59503d61cbbd8fb3e811080466763b90907d29379e78 +AUX testtools-1.8.0-twisted-backport1.patch 907 SHA256 376776dc6a7e245755bdd617aba1e263c4933319de8480ef13bb3c0d12e2423a SHA512 c1725914d9748234b705eb70b480288433248a009400403e207148fecd11660700d7edc679d4c432b48980838c17ab89a55c7b5b0eef594a0795d3b5174ebac3 WHIRLPOOL 3c5a87e0bfc1aed6801b183441435c3aff6b99fbd6b6a482af85ffea986653742b1444e59e57ad3e8ef0a7bc4ce1959152ad934d04a8e528240f88d1a8646475 +AUX testtools-1.8.0-twisted-backport2.patch 1620 SHA256 061e1d850667ad056814f04a22e6383462e45f0695e7db58e734ac2ebaaeec80 SHA512 d8a1613c04fbe7447ebf9d2750e0c28be3909071ccaa31f28c8acc8df957f23c2b98ada71684a30c2459fc10dc60b7d15b89ae4dead31bf240db86eca36fcd18 WHIRLPOOL 6743e1cc839b501c82535efe77d391016b7985e6c07aec00feef6f41c99d6efed2f93bec96c4c363769dc75e65b88be283d14ce25b677bba76b060f397eef830 +DIST testtools-0.9.36.tar.gz 201717 SHA256 20a1b0d6325f1303ff8112a272047057b73217aac85424aa4065b87641a04499 SHA512 1cb29deb2fb7cd0eebd9affb06e877487989163d0c4452db8051d75b936b0c4ac6443649d52f83cd3695421b361af7dc75507b037528ac0f7cfde9b4b201ad08 WHIRLPOOL 5561c4ef316c31f5c0099beb93eba307328669e43bef36e8da6b1856bf3f75c6b4d81fc0cb777e8397cb246512203c7951c93a52b2a5877e4764cf2e0a749e22 +DIST testtools-1.8.0.tar.gz 207976 SHA256 8afd6400fb4e75adb0b29bd09695ecb2024cd7befab4677a58c147701afadd97 SHA512 b5f0201222d1e8c60fb7c2793bcd38e1c96c6f9fae99e9f3e784d17230c9abbf7325053d501c07e752bad2da36b49e2c79a25d0c20cb9a2f426057f839a77b3a WHIRLPOOL 71d4082197a9c179862fc3c63eadc37d6ff776f0a62e5fb08c296a5bf7109dc5110a2104a1ed15ca97c523aa0afb9e7124805ec6a6ae18f7605d7641abd9c54a +DIST testtools-2.2.0.tar.gz 230716 SHA256 80f606607a6e4ce4d0e24e5b786562aa42c581906f3c070607a4265f3da65810 SHA512 f5ba08971975aa1ccf923c4c997ca7b093d00615131f440a9a5aad96d63be5b9e72f3364f3185d523fce9b5a7055bd52f767b54f7f9f17a102c4166efec189c5 WHIRLPOOL 042ef9e8177b44b37582b1b8013809b0fd443ac7c57e39317f73e081877c665fd368828e72568b89c0656ebc9d89e82c2ee7ffcd2bf0f31e07573df8573d3313 +DIST testtools-2.3.0.tar.gz 231559 SHA256 5827ec6cf8233e0f29f51025addd713ca010061204fdea77484a2934690a0559 SHA512 558fe6a1bdce7215f9f6f178f469a2b76948dc7ff0ce27400482a16683474edb81d9bf90ae48b6fcb8df9eb70759341b694aa162ed3d9d4abd372981cdcd8a64 WHIRLPOOL c4fc46381dbe3d98a1b03463bb3b52b396d6005338226deb451262484a914e673bde2fbdf64359defab2c8e5c453693f9ac4fd0233fdd4f111718c9cc0e844ec +EBUILD testtools-0.9.36.ebuild 1396 SHA256 a1574e284de9bf541836338d5ff0ef7a4158b6e76aef03804172b8a7ffc0829a SHA512 665a208a495eee6a0e9e48e426da16fe33d2925fc4650f548b13487794d818083d7281493c263555143e26e89d924e059ae2cf1f20ef10f66d5c868f381ebcb2 WHIRLPOOL 824aec21ab3ee40307d61575abd6b7d3dac69cf3ecef0d5033fda5e874114f70f2de68c6dbf60e19d3722886950ecd194a0e607abd77f3df773fb1c228627f18 +EBUILD testtools-1.8.0.ebuild 1347 SHA256 f71e505e597eee294b07fed1e0168c370c417e61525ef151c55da96c2f2c38ac SHA512 5055702fde3ba89117d7d5fe872cf77c0e2bbdd48a17c397df7048ba4228be219f950b5583ceb21be38aaa9fab3cb09925dc55e3e82637ce6db560d1bd4388f6 WHIRLPOOL ab05d853765f98c233553273a708033d5e3b753353ae89c5b861423693bfe1b828cdff24848781187c2f1c9eafd8fbd854328060f8135567225f8607d38c4b61 +EBUILD testtools-2.2.0.ebuild 1479 SHA256 b3da83869e8230f813b1eaa59d189a021bc0311effcb81e1772627f6a885a7ea SHA512 8cdc74cb31a0e5c4c1a4e8033121cadfb1def05da2e2486cf754a48663d3295b4aa40fc24a16564c3865bd2301083e57698e4bb1d30e8f9c820bce3a4af6c429 WHIRLPOOL 2d55e46dec3acfa0a1d881e1ccd92db921d117231bbb30771f58696ab1c54c424671d9834bfb48f099eadf87461c8fa22c58f1f898aa1ddace57ba89acc1e66b +EBUILD testtools-2.3.0.ebuild 1479 SHA256 adf0470b97a13ffe436b2e6fdf85fa05670abf757b9cee4d44acc6e1bef0f018 SHA512 4b0d73ce3a4541574e48f4d7fa2325245c295aa1d499c4e911ae0f5b6529e38e4cb2149a494dca97c41311dcbe89543ccba99a4df1a08f28ca709cc120024b1d WHIRLPOOL 0713b3e866a7d3eb20158781319e24a4bc41bdab21771f4f40527654408bfb656dc4c1f18738b1bda56527a9c1641c9e7d0e7beb0d98ff9d7d0bfe44ae6c4f66 +MISC ChangeLog 9820 SHA256 a5b6495fe73310f24e3b645f30f1c73e1ac4fbc201c0bef9f4baa4d7086d35ae SHA512 4f5b3dd974fbf5ed22c6b52033ab8b49b69cada8f4523a936f43a5c2c2396407327d4fd8e20ef52a0af9a7f8de0d965e647bbc16dbf88ff959827bbf22e51cb5 WHIRLPOOL d4a1ab9c4bfe069309b4e32e76554e60e546979dc074997d5761e2ecdfcae595131ce8cdd5b6f1b91084ccd3ca07e71529be64fb82f48ecb71d3b329d5263f7d +MISC ChangeLog-2015 16217 SHA256 15bad870b9a7a30ec260d755f70d6f810035d7f638ddacd6761d60f1e4bbf161 SHA512 bfc63382ec41509c4e48b4817426fc13899f96fb5794bc410b61aac080536ececc726bc95ca6222a9a024b72e4c7134d07c21d164364e63daa2c579bcc14a92d WHIRLPOOL ffaccccc7037b0d81a86bf832db96e10d6dc8a39f245e1f7b1371893468d9a8851c2789f007a1bd80abdce704128734fcc9f4c239470529c93efd1841052b2a3 +MISC metadata.xml 554 SHA256 05ab1420f1e9d87192045c3d467adfc0c911022922f980e90bc15589cc908c47 SHA512 ebe5defc73dc62044732463b2d295c08ca24573c34b689150f3865247b34ef6d925437a0c97598c3260ec037c4ed3644017601fd2b7127521c7c352edc1e6384 WHIRLPOOL 98f789c9f4bccd8dcfca7875e95290c736e1c359f53dcf6145580322a11a79c39eeae3f82bec80daea1324c3412ffba13c0b4fc907b583ad192533a587af2ddb diff --git a/dev-python/testtools/files/testtools-1.8.0-twisted-backport.patch b/dev-python/testtools/files/testtools-1.8.0-twisted-backport.patch new file mode 100644 index 000000000000..fd65b4cd6f53 --- /dev/null +++ b/dev-python/testtools/files/testtools-1.8.0-twisted-backport.patch @@ -0,0 +1,74 @@ +From 25f4800d62f339f81b09c894275a3af4b284fb62 Mon Sep 17 00:00:00 2001 +From: Colin Watson <cjwatson@canonical.com> +Date: Wed, 19 Aug 2015 03:06:09 +0100 +Subject: [PATCH] Port twisted.deferredruntest to Twisted >= 15.1.0 + +Twisted 15.1.0 removes the compatibility import of _LogObserver in +twisted.trial.unittest. This is unfortunate for us, but it's what we +get for using an internal interface. It at least still exists in +twisted.trial._synctest, so we can get it from there. + +Twisted 15.2.0 adds the new twisted.logger framework, which requires a +slight adjustment to run_with_log_observers. There's no longer a +supported interface to get hold of all log observers, but since we're +already using an internal interface (see above), what's one more? + +This passes "make check" with the current release, Twisted 15.3.0. +--- + testtools/deferredruntest.py | 27 +++++++++++++++++++++++---- + 1 file changed, 23 insertions(+), 4 deletions(-) + +diff --git a/testtools/deferredruntest.py b/testtools/deferredruntest.py +index c33e14a..04cdb0f 100644 +--- a/testtools/deferredruntest.py ++++ b/testtools/deferredruntest.py +@@ -27,8 +27,15 @@ + ) + + from twisted.internet import defer ++try: ++ from twisted.logger import globalLogPublisher ++except ImportError: ++ globalLogPublisher = None + from twisted.python import log +-from twisted.trial.unittest import _LogObserver ++try: ++ from twisted.trial.unittest import _LogObserver ++except ImportError: ++ from twisted.trial._synctest import _LogObserver + + + class _DeferredRunTest(RunTest): +@@ -53,9 +60,21 @@ def _run_user(self, function, *args): + + def run_with_log_observers(observers, function, *args, **kwargs): + """Run 'function' with the given Twisted log observers.""" +- real_observers = list(log.theLogPublisher.observers) ++ if globalLogPublisher is not None: ++ # Twisted >= 15.2.0, with the new twisted.logger framework. ++ # log.theLogPublisher.observers will only contain legacy observers; ++ # we need to look at globalLogPublisher._observers, which contains ++ # both legacy and modern observers, and add and remove them via ++ # globalLogPublisher. However, we must still add and remove the ++ # observers we want to run with via log.theLogPublisher, because ++ # _LogObserver may consider old keys and require them to be mapped. ++ publisher = globalLogPublisher ++ real_observers = list(publisher._observers) ++ else: ++ publisher = log.theLogPublisher ++ real_observers = list(publisher.observers) + for observer in real_observers: +- log.theLogPublisher.removeObserver(observer) ++ publisher.removeObserver(observer) + for observer in observers: + log.theLogPublisher.addObserver(observer) + try: +@@ -64,7 +83,7 @@ def run_with_log_observers(observers, function, *args, **kwargs): + for observer in observers: + log.theLogPublisher.removeObserver(observer) + for observer in real_observers: +- log.theLogPublisher.addObserver(observer) ++ publisher.addObserver(observer) + + + # Observer of the Twisted log that we install during tests. diff --git a/dev-python/testtools/files/testtools-1.8.0-twisted-backport1.patch b/dev-python/testtools/files/testtools-1.8.0-twisted-backport1.patch new file mode 100644 index 000000000000..c1eb11b1f5ab --- /dev/null +++ b/dev-python/testtools/files/testtools-1.8.0-twisted-backport1.patch @@ -0,0 +1,33 @@ +From 6d821b5770b01f5ec98c3b8db734fffeebf12b62 Mon Sep 17 00:00:00 2001 +From: Colin Watson <cjwatson@canonical.com> +Date: Mon, 24 Aug 2015 13:21:57 +0100 +Subject: [PATCH] Test with Twisted 13.0.0/15.2.0. + +--- + .travis.yml | 6 +++++- + 1 file changed, 5 insertions(+), 1 deletion(-) + +diff --git a/.travis.yml b/.travis.yml +index 41036f8..a706b27 100644 +--- a/.travis.yml ++++ b/.travis.yml +@@ -7,6 +7,10 @@ python: + - "3.4" + - "pypy" + ++env: ++ - TWISTED="==13.0.0" ++ - TWISTED="==15.2.0" ++ + # We have to pin Jinja2 < 2.7 for Python 3.2 because 2.7 drops/breaks support: + # http://jinja.pocoo.org/docs/changelog/#version-2-7 + # And Spinx to < 1.3 for pypy3 and python 3.2 similarly. +@@ -23,7 +27,7 @@ matrix: + env: SPHINX="<1.3" + + install: +- - pip install fixtures $JINJA_REQ sphinx$SPHINX ++ - pip install fixtures $JINJA_REQ sphinx$SPHINX Twisted$TWISTED + - python setup.py install + + script: diff --git a/dev-python/testtools/files/testtools-1.8.0-twisted-backport2.patch b/dev-python/testtools/files/testtools-1.8.0-twisted-backport2.patch new file mode 100644 index 000000000000..df5d91f9b681 --- /dev/null +++ b/dev-python/testtools/files/testtools-1.8.0-twisted-backport2.patch @@ -0,0 +1,57 @@ +From 2e03ffaff15bc5d83c5f6d092aab4072f166aca0 Mon Sep 17 00:00:00 2001 +From: Colin Watson <cjwatson@canonical.com> +Date: Mon, 24 Aug 2015 13:45:01 +0100 +Subject: [PATCH] Only run Twisted tests on Python 2. + +--- + .travis.yml | 22 ++++++++++++++++------ + 1 file changed, 16 insertions(+), 6 deletions(-) + +diff --git a/.travis.yml b/.travis.yml +index a706b27..bc007f2 100644 +--- a/.travis.yml ++++ b/.travis.yml +@@ -7,27 +7,37 @@ python: + - "3.4" + - "pypy" + +-env: +- - TWISTED="==13.0.0" +- - TWISTED="==15.2.0" +- + # We have to pin Jinja2 < 2.7 for Python 3.2 because 2.7 drops/breaks support: + # http://jinja.pocoo.org/docs/changelog/#version-2-7 +-# And Spinx to < 1.3 for pypy3 and python 3.2 similarly. ++# And Sphinx to < 1.3 for pypy3 and python 3.2 similarly. + # + # See also: + # http://stackoverflow.com/questions/18252804/syntax-error-in-jinja-2-library ++# ++# Twisted tests currently only work on Python 2. + matrix: + include: ++ - python: "2.6" ++ env: ++ - TWISTED_REQ="Twisted==13.0.0" ++ - TWISTED_REQ="Twisted==15.2.0" ++ - python: "2.7" ++ env: ++ - TWISTED_REQ="Twisted==13.0.0" ++ - TWISTED_REQ="Twisted==15.2.0" + - python: "3.2" + env: + - JINJA_REQ="jinja2<2.7, Pygments<2.0" + - SPHINX="<1.3" ++ - python: "pypy" ++ env: ++ - TWISTED_REQ="Twisted==13.0.0" ++ - TWISTED_REQ="Twisted==15.2.0" + - python: "pypy3" + env: SPHINX="<1.3" + + install: +- - pip install fixtures $JINJA_REQ sphinx$SPHINX Twisted$TWISTED ++ - pip install fixtures $JINJA_REQ sphinx$SPHINX $TWISTED_REQ + - python setup.py install + + script: diff --git a/dev-python/testtools/metadata.xml b/dev-python/testtools/metadata.xml new file mode 100644 index 000000000000..d2fbb03bb6cd --- /dev/null +++ b/dev-python/testtools/metadata.xml @@ -0,0 +1,17 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd"> +<pkgmetadata> + <maintainer type="project"> + <email>python@gentoo.org</email> + <name>Python</name> + </maintainer> + <maintainer type="project"> + <email>openstack@gentoo.org</email> + <name>Openstack</name> + </maintainer> + <upstream> + <remote-id type="pypi">testtools</remote-id> + <remote-id type="github">testing-cabal/testtools</remote-id> + <remote-id type="launchpad">testtools</remote-id> + </upstream> +</pkgmetadata> diff --git a/dev-python/testtools/testtools-0.9.36.ebuild b/dev-python/testtools/testtools-0.9.36.ebuild new file mode 100644 index 000000000000..b3963b9dd457 --- /dev/null +++ b/dev-python/testtools/testtools-0.9.36.ebuild @@ -0,0 +1,50 @@ +# Copyright 1999-2017 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +EAPI=5 + +PYTHON_COMPAT=( python2_7 python3_{4,5,6} pypy ) +PYTHON_REQ_USE="threads(+)" + +inherit distutils-r1 versionator + +#SERIES="$(get_version_component_range 1-2)" +SERIES="trunk" + +DESCRIPTION="Extensions to the Python unittest library" +HOMEPAGE="https://launchpad.net/testtools https://pypi.python.org/pypi/testtools" +SRC_URI="https://launchpad.net/${PN}/${SERIES}/${PV}/+download/${P}.tar.gz" + +LICENSE="MIT" +SLOT="0" +KEYWORDS="alpha amd64 arm ~arm64 hppa ia64 ~mips ppc ppc64 ~s390 ~sh sparc x86 ~amd64-fbsd ~x86-fbsd ~amd64-linux ~x86-linux" +IUSE="doc test" + +RDEPEND="dev-python/mimeparse[${PYTHON_USEDEP}] + dev-python/extras[${PYTHON_USEDEP}]" +DEPEND="${RDEPEND} + dev-python/setuptools[${PYTHON_USEDEP}] + doc? ( dev-python/sphinx[${PYTHON_USEDEP}] ) + test? ( $(python_gen_cond_dep 'dev-python/twisted-core[${PYTHON_USEDEP}]' python2_7) )" + +python_compile_all() { + use doc && emake -C doc html +} + +python_prepare_all() { + # Take out failing tests + # https://bugs.launchpad.net/testtools/+bug/1380918 + sed -e 's:test_test_module:_&:' -e 's:test_test_suite:_&:' \ + -i testtools/tests/test_distutilscmd.py || die + + distutils-r1_python_prepare_all +} + +python_test() { + esetup.py test +} + +python_install_all() { + use doc && HTML_DOCS=( doc/_build/html/. ) + distutils-r1_python_install_all +} diff --git a/dev-python/testtools/testtools-1.8.0.ebuild b/dev-python/testtools/testtools-1.8.0.ebuild new file mode 100644 index 000000000000..33c0a7d8f7e6 --- /dev/null +++ b/dev-python/testtools/testtools-1.8.0.ebuild @@ -0,0 +1,52 @@ +# Copyright 1999-2017 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +EAPI=5 + +PYTHON_COMPAT=( python2_7 python3_{4,5,6} pypy pypy3 ) +PYTHON_REQ_USE="threads(+)" + +inherit distutils-r1 + +DESCRIPTION="Extensions to the Python standard library unit testing framework" +HOMEPAGE="https://github.com/testing-cabal/testtools" +SRC_URI="mirror://pypi/${P:0:1}/${PN}/${P}.tar.gz" + +LICENSE="MIT" +SLOT="0" +KEYWORDS="alpha amd64 arm arm64 hppa ia64 ~m68k ~mips ppc ppc64 ~s390 ~sh sparc x86 ~amd64-fbsd ~x86-fbsd ~amd64-linux ~x86-linux" +IUSE="doc test" + +CDEPEND=" + dev-python/extras[${PYTHON_USEDEP}] + dev-python/mimeparse[${PYTHON_USEDEP}] + >=dev-python/pbr-0.11[${PYTHON_USEDEP}] + >=dev-python/unittest2-1.0.0[${PYTHON_USEDEP}] + dev-python/traceback2[${PYTHON_USEDEP}] +" +DEPEND=" + dev-python/setuptools[${PYTHON_USEDEP}] + ${CDEPEND} + doc? ( dev-python/sphinx[${PYTHON_USEDEP}] ) +" +RDEPEND="${CDEPEND}" + +PATCHES=( + "${FILESDIR}"/${P}-twisted-backport.patch + "${FILESDIR}"/${P}-twisted-backport1.patch + "${FILESDIR}"/${P}-twisted-backport2.patch +) + +python_compile_all() { + use doc && emake -C doc html +} + +python_test() { + "${PYTHON}" -m testtools.run testtools.tests.test_suite || die "tests failed under ${EPYTHON}" +} + +python_install_all() { + use doc && HTML_DOCS=( doc/_build/html/. ) + + distutils-r1_python_install_all +} diff --git a/dev-python/testtools/testtools-2.2.0.ebuild b/dev-python/testtools/testtools-2.2.0.ebuild new file mode 100644 index 000000000000..5ede99ec3bb7 --- /dev/null +++ b/dev-python/testtools/testtools-2.2.0.ebuild @@ -0,0 +1,53 @@ +# Copyright 1999-2017 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +EAPI=5 + +PYTHON_COMPAT=( python2_7 python3_4 python3_5 python3_6 pypy pypy3 ) +PYTHON_REQ_USE="threads(+)" + +inherit distutils-r1 + +DESCRIPTION="Extensions to the Python standard library unit testing framework" +HOMEPAGE="https://github.com/testing-cabal/testtools" +SRC_URI="mirror://pypi/${P:0:1}/${PN}/${P}.tar.gz" + +LICENSE="MIT" +SLOT="0" +KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~amd64-fbsd ~x86-fbsd ~amd64-linux ~x86-linux" +IUSE="doc test" + +CDEPEND=" + >=dev-python/extras-1.0.0[${PYTHON_USEDEP}] + dev-python/mimeparse[${PYTHON_USEDEP}] + >=dev-python/pbr-0.11[${PYTHON_USEDEP}] + dev-python/pyrsistent[${PYTHON_USEDEP}] + >=dev-python/six-1.4.0[${PYTHON_USEDEP}] + dev-python/traceback2[${PYTHON_USEDEP}] + >=dev-python/unittest2-1.0.0[${PYTHON_USEDEP}] +" +DEPEND=" + dev-python/setuptools[${PYTHON_USEDEP}] + ${CDEPEND} + doc? ( dev-python/sphinx[${PYTHON_USEDEP}] ) + test? ( + >=dev-python/fixtures-1.3.0[${PYTHON_USEDEP}] + dev-python/testscenarios[${PYTHON_USEDEP}] + ) +" +RDEPEND="${CDEPEND}" +PDEPEND=">=dev-python/fixtures-1.3.0[${PYTHON_USEDEP}]" + +python_compile_all() { + use doc && emake -C doc html +} + +python_test() { + "${PYTHON}" -m testtools.run testtools.tests.test_suite || die "tests failed under ${EPYTHON}" +} + +python_install_all() { + use doc && HTML_DOCS=( doc/_build/html/. ) + + distutils-r1_python_install_all +} diff --git a/dev-python/testtools/testtools-2.3.0.ebuild b/dev-python/testtools/testtools-2.3.0.ebuild new file mode 100644 index 000000000000..bd556b22d4a8 --- /dev/null +++ b/dev-python/testtools/testtools-2.3.0.ebuild @@ -0,0 +1,53 @@ +# Copyright 1999-2017 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +EAPI=6 + +PYTHON_COMPAT=( python2_7 python3_4 python3_5 python3_6 pypy pypy3 ) +PYTHON_REQ_USE="threads(+)" + +inherit distutils-r1 + +DESCRIPTION="Extensions to the Python standard library unit testing framework" +HOMEPAGE="https://github.com/testing-cabal/testtools" +SRC_URI="mirror://pypi/${P:0:1}/${PN}/${P}.tar.gz" + +LICENSE="MIT" +SLOT="0" +KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~amd64-fbsd ~x86-fbsd ~amd64-linux ~x86-linux" +IUSE="doc test" + +CDEPEND=" + >=dev-python/extras-1.0.0[${PYTHON_USEDEP}] + dev-python/mimeparse[${PYTHON_USEDEP}] + >=dev-python/pbr-0.11[${PYTHON_USEDEP}] + dev-python/pyrsistent[${PYTHON_USEDEP}] + >=dev-python/six-1.4.0[${PYTHON_USEDEP}] + dev-python/traceback2[${PYTHON_USEDEP}] + >=dev-python/unittest2-1.0.0[${PYTHON_USEDEP}] +" +DEPEND=" + dev-python/setuptools[${PYTHON_USEDEP}] + ${CDEPEND} + doc? ( dev-python/sphinx[${PYTHON_USEDEP}] ) + test? ( + >=dev-python/fixtures-1.3.0[${PYTHON_USEDEP}] + dev-python/testscenarios[${PYTHON_USEDEP}] + ) +" +RDEPEND="${CDEPEND}" +PDEPEND=">=dev-python/fixtures-1.3.0[${PYTHON_USEDEP}]" + +python_compile_all() { + use doc && emake -C doc html +} + +python_test() { + "${PYTHON}" -m testtools.run testtools.tests.test_suite || die "tests failed under ${EPYTHON}" +} + +python_install_all() { + use doc && HTML_DOCS=( doc/_build/html/. ) + + distutils-r1_python_install_all +} |