diff options
author | V3n3RiX <venerix@redcorelinux.org> | 2018-07-14 21:03:06 +0100 |
---|---|---|
committer | V3n3RiX <venerix@redcorelinux.org> | 2018-07-14 21:03:06 +0100 |
commit | 8376ef56580626e9c0f796d5b85b53a0a1c7d5f5 (patch) | |
tree | 7681bbd4e8b05407772df40a4bf04cbbc8afc3fa /dev-python/manuel | |
parent | 30a9caf154332f12ca60756e1b75d2f0e3e1822d (diff) |
gentoo resync : 14.07.2018
Diffstat (limited to 'dev-python/manuel')
-rw-r--r-- | dev-python/manuel/Manifest | 4 | ||||
-rw-r--r-- | dev-python/manuel/files/manuel-1.8.0-rm_zope_test.patch | 120 | ||||
-rw-r--r-- | dev-python/manuel/manuel-1.8.0.ebuild | 31 | ||||
-rw-r--r-- | dev-python/manuel/metadata.xml | 12 |
4 files changed, 167 insertions, 0 deletions
diff --git a/dev-python/manuel/Manifest b/dev-python/manuel/Manifest new file mode 100644 index 000000000000..d62c45edaaa6 --- /dev/null +++ b/dev-python/manuel/Manifest @@ -0,0 +1,4 @@ +AUX manuel-1.8.0-rm_zope_test.patch 3693 BLAKE2B 444261de258ddc0a24aa2eaf517385712da421c6a8dc322c45e6bc980a87e10c22b6f10285d1d4352ae3542999d53f2bffc71b833d7bd9181b8708b2fde957cd SHA512 47dbc28c5d66895c764997de7a5c04aefd92de6aac6094f8184de849f906e5a1650e2c483868bf5ce77e7d81893f51410a19d7d38f732b4e0a1e54bb728836e9 +DIST manuel-1.8.0.tar.gz 207600 BLAKE2B f7bad36491d49254c7aea17550cbd4fa00b6c3c122061586785da4bddc514f51a2d5a8df3b048fe78c7b01036ca903330ea614c998fdd04d1e8cca002930c962 SHA512 8099df44cfd28c8ac6256f346bf8cd36091893a38d3c297099866b1a5db97286b9c9e69f3f12054d7eee9ae3985ca0a003d7b2cc082d28d59850bbcad6b57c57 +EBUILD manuel-1.8.0.ebuild 730 BLAKE2B 67bc13c2d8f8e55bc488a417fc4b0a6564441e51b2770b7e137a1826d8ef0ee2576af8760a61d7810dfc4e32c931faec44625703f3915dd85d89030aeb3b5adf SHA512 52ec0ace37f71e5943c6ad297cd228ebc5ee98f737398ed2e5d89e8917559a155ad4b491120538019faf594de98beddfa18ce5b8d1b8814572f2e322fd82d2a4 +MISC metadata.xml 378 BLAKE2B a015eb99ca98c46e7636f0203ad982b5e60687e7a753548f05dba16c968d42ce355e786be237a66180e7d6834cbd1a2c273113604274e4e0c1befd92c35e2668 SHA512 a90d635b0d109936cb39e2b016464e6c6220ff02b6d6f640d30045782ffb85bccc9e408119897947b11d8fa234451820bef9bd1f49264dc72c7b0ebe36f1edac diff --git a/dev-python/manuel/files/manuel-1.8.0-rm_zope_test.patch b/dev-python/manuel/files/manuel-1.8.0-rm_zope_test.patch new file mode 100644 index 000000000000..d1b61cc678ab --- /dev/null +++ b/dev-python/manuel/files/manuel-1.8.0-rm_zope_test.patch @@ -0,0 +1,120 @@ + setup.py | 6 ------ + src/manuel/index.txt | 26 ++++++++------------------ + src/manuel/tests.py | 13 +++++++++---- + 3 files changed, 17 insertions(+), 28 deletions(-) + +diff --git a/setup.py b/setup.py +index 4561779..b6730c8 100644 +--- a/setup.py ++++ b/setup.py +@@ -20,8 +20,6 @@ with open('README.rst') as readme: + with open('CHANGES.rst') as changes: + long_description = readme.read() + '\n\n' + changes.read() + +-tests_require = ['zope.testing'] +- + setup( + name='manuel', + version='1.8.0', +@@ -44,10 +42,6 @@ setup( + 'License :: OSI Approved :: Apache Software License', + ], + license='Apache Software License, Version 2.0', +- extras_require={ +- 'tests': tests_require, +- }, +- tests_require=tests_require, + test_suite='manuel.tests.test_suite', + install_requires=[ + 'setuptools', +diff --git a/src/manuel/index.txt b/src/manuel/index.txt +index c1d85f3..a315317 100644 +--- a/src/manuel/index.txt ++++ b/src/manuel/index.txt +@@ -166,16 +166,16 @@ can pass in your own class to `TestSuite`. + + .. code-block:: python + +- import os.path +- import manuel.testing ++ import os.path ++ import manuel.testing + +- class StripDirsTestCase(manuel.testing.TestCase): +- def shortDescription(self): +- return os.path.basename(str(self)) +- suite = manuel.testing.TestSuite( +- m, path_to_test, TestCase=StripDirsTestCase) ++ class StripDirsTestCase(manuel.testing.TestCase): ++ def shortDescription(self): ++ return os.path.basename(str(self)) ++ suite = manuel.testing.TestSuite( ++ m, path_to_test, TestCase=StripDirsTestCase) + +- >>> list(suite)[0].shortDescription() ++ list(suite)[0].shortDescription() + 'bugs.txt' + + +@@ -236,16 +236,6 @@ checkers <http://docs.python.org/library/doctest.html#outputchecker-objects>`_ + smoothes over the differences between CPython's and PyPy's NameError + messages: + +-.. code-block:: python +- +- import re +- import zope.testing.renormalizing +- checker = zope.testing.renormalizing.RENormalizing([ +- (re.compile(r"NameError: global name '([a-zA-Z0-9_]+)' is not defined"), +- r"NameError: name '\1' is not defined"), +- ]) +- +- + .. reset-globs + .. _capture: + +diff --git a/src/manuel/tests.py b/src/manuel/tests.py +index 07723a6..b1a3a76 100644 +--- a/src/manuel/tests.py ++++ b/src/manuel/tests.py +@@ -11,11 +11,12 @@ import manuel.testing + import os.path + import re + import unittest +-import zope.testing.renormalizing + + here = os.path.dirname(os.path.abspath(__file__)) + +-checker = zope.testing.renormalizing.RENormalizing([ ++try: ++ import zope.testing.renormalizing ++ checker = zope.testing.renormalizing.RENormalizing([ + (re.compile(r"<unittest\.result\.TestResult"), '<unittest.TestResult'), + # PyPy spells some error messages differently + (re.compile(r"NameError: global name '([a-zA-Z0-9_]+)' is not defined"), +@@ -25,7 +26,9 @@ checker = zope.testing.renormalizing.RENormalizing([ + r"<\1 object"), + (re.compile(r"<SRE_Match object"), + r"<_sre.SRE_Match object"), +-]) ++ ]) ++except ImportError: ++ pass + + + def turtle_on_the_bottom_test(): +@@ -59,7 +62,6 @@ def test_suite(): + optionflags = doctest.NORMALIZE_WHITESPACE | doctest.ELLIPSIS + + m = manuel.ignore.Manuel() +- m += manuel.doctest.Manuel(optionflags=optionflags, checker=checker) + m += manuel.codeblock.Manuel() + m += manuel.capture.Manuel() + m += manuel.testcase.SectionManuel() +@@ -73,3 +75,6 @@ def test_suite(): + suite, + doctest.DocTestSuite(), + )) ++ ++if __name__ == '__main__': ++ unittest.TextTestRunner().run(test_suite()) diff --git a/dev-python/manuel/manuel-1.8.0.ebuild b/dev-python/manuel/manuel-1.8.0.ebuild new file mode 100644 index 000000000000..8b9197a65bb4 --- /dev/null +++ b/dev-python/manuel/manuel-1.8.0.ebuild @@ -0,0 +1,31 @@ +# Copyright 1999-2017 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +EAPI=5 + +PYTHON_COMPAT=( python{2_7,3_{4,5,6}} pypy ) + +inherit distutils-r1 + +DESCRIPTION="Manuel lets you build tested documentation" +HOMEPAGE="https://github.com/benji-york/manuel/ https://pypi.org/project/manuel/" +SRC_URI="mirror://pypi/${PN:0:1}/${PN}/${P}.tar.gz" + +LICENSE="Apache-2.0" +SLOT="0" +KEYWORDS="amd64 x86" +IUSE="" + +RDEPEND="dev-python/six[${PYTHON_USEDEP}]" +DEPEND="${RDEPEND} + dev-python/setuptools[${PYTHON_USEDEP}]" +# Required to run tests +DISTUTILS_IN_SOURCE_BUILD=1 + +DOCS=( CHANGES.rst ) + +PATCHES=( "${FILESDIR}"/${P}-rm_zope_test.patch ) + +python_test() { + PYTHONPATH=src/:${PYTHONPATH} esetup.py test +} diff --git a/dev-python/manuel/metadata.xml b/dev-python/manuel/metadata.xml new file mode 100644 index 000000000000..cfc835588bcb --- /dev/null +++ b/dev-python/manuel/metadata.xml @@ -0,0 +1,12 @@ +<?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> + <upstream> + <remote-id type="github">benji-york/manuel</remote-id> + <remote-id type="pypi">manuel</remote-id> + </upstream> +</pkgmetadata> |