From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by finch.gentoo.org (Postfix) with ESMTPS id 55876138350 for ; Sat, 25 Apr 2020 00:37:35 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 5D928E0BFC; Sat, 25 Apr 2020 00:37:30 +0000 (UTC) Received: from smtp.gentoo.org (smtp.gentoo.org [140.211.166.183]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id 3117EE0BFC for ; Sat, 25 Apr 2020 00:37:30 +0000 (UTC) Received: from oystercatcher.gentoo.org (unknown [IPv6:2a01:4f8:202:4333:225:90ff:fed9:fc84]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id 0B8EB34F1B0 for ; Sat, 25 Apr 2020 00:37:29 +0000 (UTC) Received: from localhost.localdomain (localhost [IPv6:::1]) by oystercatcher.gentoo.org (Postfix) with ESMTP id 32E42207 for ; Sat, 25 Apr 2020 00:37:25 +0000 (UTC) From: "Alessandro Barbieri" To: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: 8bit Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "Alessandro Barbieri" Message-ID: <1587775036.5e90c0ac0f421d3163faab593c367cce6b4602cb.Alessandro-Barbieri@gentoo> Subject: [gentoo-commits] repo/proj/guru:dev commit in: dev-python/ukpostcodeparser/, dev-python/ukpostcodeparser/files/ X-VCS-Repository: repo/proj/guru X-VCS-Files: dev-python/ukpostcodeparser/Manifest dev-python/ukpostcodeparser/files/ukpostcodeparser-1.1.2-test.patch dev-python/ukpostcodeparser/metadata.xml dev-python/ukpostcodeparser/ukpostcodeparser-1.1.2.ebuild X-VCS-Directories: dev-python/ukpostcodeparser/files/ dev-python/ukpostcodeparser/ X-VCS-Committer: Alessandro-Barbieri X-VCS-Committer-Name: Alessandro Barbieri X-VCS-Revision: 5e90c0ac0f421d3163faab593c367cce6b4602cb X-VCS-Branch: dev Date: Sat, 25 Apr 2020 00:37:25 +0000 (UTC) Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-commits@lists.gentoo.org X-Auto-Response-Suppress: DR, RN, NRN, OOF, AutoReply X-Archives-Salt: 3245acae-9dcf-49fc-b808-7035ecb42b89 X-Archives-Hash: 66343dcdca18db745972ec32a73dc2b3 commit: 5e90c0ac0f421d3163faab593c367cce6b4602cb Author: Alessandro Barbieri gmail com> AuthorDate: Fri Apr 24 22:44:15 2020 +0000 Commit: Alessandro Barbieri gmail com> CommitDate: Sat Apr 25 00:37:16 2020 +0000 URL: https://gitweb.gentoo.org/repo/proj/guru.git/commit/?id=5e90c0ac dev-python/ukpostcodeparser: new package Package-Manager: Portage-2.3.99, Repoman-2.3.22 Signed-off-by: Alessandro Barbieri gmail.com> dev-python/ukpostcodeparser/Manifest | 1 + .../files/ukpostcodeparser-1.1.2-test.patch | 70 ++++++++++++++++++++++ dev-python/ukpostcodeparser/metadata.xml | 15 +++++ .../ukpostcodeparser/ukpostcodeparser-1.1.2.ebuild | 30 ++++++++++ 4 files changed, 116 insertions(+) diff --git a/dev-python/ukpostcodeparser/Manifest b/dev-python/ukpostcodeparser/Manifest new file mode 100644 index 0000000..12535d7 --- /dev/null +++ b/dev-python/ukpostcodeparser/Manifest @@ -0,0 +1 @@ +DIST ukpostcodeparser-1.1.2.tar.gz 5585 BLAKE2B c95f215f0e4b222b85ec3ab0a8d82186845d9cb161098240411a425094ada391bb6c891904293cca4a56e9370217829b51ba30e91824dd3d762279baef6c65f7 SHA512 8113522b728c095f937a9f53f21c369130e3e63c4fc3546dbea4ad1c53648742fb0e766b1254c76ee65d69dec585f1a90caa7d39ca540de1765ff5f989a702de diff --git a/dev-python/ukpostcodeparser/files/ukpostcodeparser-1.1.2-test.patch b/dev-python/ukpostcodeparser/files/ukpostcodeparser-1.1.2-test.patch new file mode 100644 index 0000000..fd08a55 --- /dev/null +++ b/dev-python/ukpostcodeparser/files/ukpostcodeparser-1.1.2-test.patch @@ -0,0 +1,70 @@ +--- ../ukpostcodeparser/test/parser.py 2018-12-19 17:55:53.435338634 +0200 ++++ ../ukpostcodeparser/test/parser.py 2018-12-19 17:56:54.075385419 +0200 +@@ -796,14 +796,6 @@ + expected=InvalidPostcodeError + ) + +- def test_091(self): +- self.run_parser( +- postcode='w1m 4zz', +- strict=True, +- incode_mandatory=False, +- expected=InvalidPostcodeError +- ) +- + def test_092(self): + self.run_parser( + postcode='3r0', +@@ -844,22 +836,6 @@ + expected=('GIR', '') + ) + +- def test_097(self): +- self.run_parser( +- postcode='w1m 4zz', +- strict=True, +- incode_mandatory=False, +- expected=InvalidPostcodeError +- ) +- +- def test_098(self): +- self.run_parser( +- postcode='w1m', +- strict=True, +- incode_mandatory=False, +- expected=InvalidPostcodeError +- ) +- + def test_099(self): + self.run_parser( + postcode='dn169aaA', +@@ -1068,14 +1044,6 @@ + expected=InvalidPostcodeError + ) + +- def test_125(self): +- self.run_parser( +- postcode='w1m 4zz', +- strict=True, +- incode_mandatory=True, +- expected=InvalidPostcodeError +- ) +- + def test_126(self): + self.run_parser( + postcode='3r0', +@@ -1116,14 +1084,6 @@ + expected=IncodeNotFoundError + ) + +- def test_131(self): +- self.run_parser( +- postcode='w1m 4zz', +- strict=True, +- incode_mandatory=True, +- expected=InvalidPostcodeError +- ) +- + def test_132(self): + self.run_parser( + postcode='w1m', diff --git a/dev-python/ukpostcodeparser/metadata.xml b/dev-python/ukpostcodeparser/metadata.xml new file mode 100644 index 0000000..f34e585 --- /dev/null +++ b/dev-python/ukpostcodeparser/metadata.xml @@ -0,0 +1,15 @@ + + + + + lssndrbarbieri@gmail.com + Alessandro Barbieri + + + UK Postcode parser + + + hamstah/ukpostcodeparser + UkPostcodeParser + + diff --git a/dev-python/ukpostcodeparser/ukpostcodeparser-1.1.2.ebuild b/dev-python/ukpostcodeparser/ukpostcodeparser-1.1.2.ebuild new file mode 100644 index 0000000..0469203 --- /dev/null +++ b/dev-python/ukpostcodeparser/ukpostcodeparser-1.1.2.ebuild @@ -0,0 +1,30 @@ +# Copyright 1999-2020 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI="7" + +PYTHON_COMPAT=( pypy3 python3_{6,7,8} ) + +inherit distutils-r1 + +DESCRIPTION="UK postcode parser library" +HOMEPAGE="https://github.com/hamstah/ukpostcodeparser" +SRC_URI="https://github.com/hamstah/${PN}/archive/v${PV}.tar.gz -> ${P}.tar.gz" + +LICENSE="MIT" +SLOT="0" +KEYWORDS="~amd64 ~x86" +IUSE="test" +RESTRICT="!test? ( test )" + +# https://github.com/hamstah/ukpostcodeparser/issues/8 +PATCHES=( "${FILESDIR}/${P}-test.patch" ) + +python_test() { + "${PYTHON}" -m unittest discover -v -s ukpostcodeparser/test -p parser.py || die "tests failed with ${EPYTHON}" +} + +python_install_all() { + distutils-r1_python_install_all + find "${ED}" -type d -name "test" -exec rm -rv {} + || die "tests removing failed" +}