summaryrefslogtreecommitdiff
path: root/dev-python/vcrpy
diff options
context:
space:
mode:
authorPalica <palica+gitlab@liguros.net>2020-06-23 22:35:08 +0200
committerPalica <palica+gitlab@liguros.net>2020-06-23 22:35:08 +0200
commitecdac123787b96ce6649f0f91da12ea6458cc2b1 (patch)
treeb89c74d9e6fe6e8aebc4c77bcbeb4ab73214127d /dev-python/vcrpy
parent1be72aa41cf41dedadeecf59dca9f01de6381f5e (diff)
downloadbaldeagleos-repo-ecdac123787b96ce6649f0f91da12ea6458cc2b1.tar.gz
baldeagleos-repo-ecdac123787b96ce6649f0f91da12ea6458cc2b1.tar.xz
baldeagleos-repo-ecdac123787b96ce6649f0f91da12ea6458cc2b1.zip
Updating liguros repo
Diffstat (limited to 'dev-python/vcrpy')
-rw-r--r--dev-python/vcrpy/Manifest1
-rw-r--r--dev-python/vcrpy/metadata.xml13
-rw-r--r--dev-python/vcrpy/vcrpy-4.0.2.ebuild50
3 files changed, 64 insertions, 0 deletions
diff --git a/dev-python/vcrpy/Manifest b/dev-python/vcrpy/Manifest
new file mode 100644
index 000000000000..899e2bb966f2
--- /dev/null
+++ b/dev-python/vcrpy/Manifest
@@ -0,0 +1 @@
+DIST vcrpy-4.0.2.tar.gz 324196 BLAKE2B 8910ba40bd56c7836a92c120c480e633063c78beb1d7c4dcfffb6180135cf0e28586410307ba3e19b3fa484a72a176dbf877f781ade7bae7c81110fde2eedd32 SHA512 17eebc9574ff14f97ad200b99c50b0440a93fbf38afe8ad95f443370d84c43177ac55ab655ffea7e7985b0cd76124eff3c394898e71a0ba0c434014f07e526f9
diff --git a/dev-python/vcrpy/metadata.xml b/dev-python/vcrpy/metadata.xml
new file mode 100644
index 000000000000..4c097df15341
--- /dev/null
+++ b/dev-python/vcrpy/metadata.xml
@@ -0,0 +1,13 @@
+<?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">kevin1024/vcrpy</remote-id>
+ <remote-id type="pypi">vcrpy</remote-id>
+ </upstream>
+ <origin>gentoo-staging</origin>
+</pkgmetadata>
diff --git a/dev-python/vcrpy/vcrpy-4.0.2.ebuild b/dev-python/vcrpy/vcrpy-4.0.2.ebuild
new file mode 100644
index 000000000000..b538d90a9181
--- /dev/null
+++ b/dev-python/vcrpy/vcrpy-4.0.2.ebuild
@@ -0,0 +1,50 @@
+# Copyright 1999-2020 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+
+PYTHON_COMPAT=( python3_{6..9} )
+
+inherit distutils-r1
+
+DESCRIPTION="Automatically mock your HTTP interactions to simplify and speed up testing"
+HOMEPAGE="https://github.com/kevin1024/vcrpy"
+#SRC_URI="mirror://pypi/${PN:0:1}/${PN}/${P}.tar.gz"
+SRC_URI="https://github.com/kevin1024/vcrpy/archive/v${PV}.tar.gz -> ${P}.tar.gz"
+
+LICENSE="Apache-2.0"
+SLOT="0"
+KEYWORDS="~alpha amd64 ~arm ~arm64 ~hppa ~ia64 ~ppc ~ppc64 ~s390 ~sparc x86"
+
+RDEPEND="
+ >=dev-python/httplib2-0.9.1[${PYTHON_USEDEP}]
+ dev-python/pyyaml[${PYTHON_USEDEP}]
+ dev-python/requests[${PYTHON_USEDEP}]
+ >=dev-python/six-1.5[${PYTHON_USEDEP}]
+ dev-python/urllib3[${PYTHON_USEDEP}]
+ dev-python/wrapt[${PYTHON_USEDEP}]
+ dev-python/yarl[${PYTHON_USEDEP}]
+ "
+BDEPEND="
+ test? (
+ dev-python/pytest-httpbin[${PYTHON_USEDEP}]
+ )"
+
+distutils_enable_tests pytest
+
+src_prepare() {
+ # tests requiring Internet
+ rm tests/integration/test_aiohttp.py || die
+ sed -e 's:test_flickr_should_respond_with_200:_&:' \
+ -e 's:test_amazon_doctype:_&:' \
+ -i tests/integration/test_wild.py || die
+ sed -e 's:testing_connect:_&:' \
+ -i tests/unit/test_stubs.py || die
+
+ distutils-r1_src_prepare
+}
+
+python_test() {
+ local -x REQUESTS_CA_BUNDLE=$("${EPYTHON}" -m pytest_httpbin.certs)
+ pytest -vv || die "Tests fail with ${EPYTHON}"
+}