From 908778078736bd36f7a60a2d576d415cb8e000fa Mon Sep 17 00:00:00 2001 From: V3n3RiX Date: Sat, 22 May 2021 07:31:18 +0100 Subject: gentoo resync : 22.05.2021 --- dev-python/stripe/Manifest | 2 ++ dev-python/stripe/stripe-2.57.0.ebuild | 63 ++++++++++++++++++++++++++++++++++ 2 files changed, 65 insertions(+) create mode 100644 dev-python/stripe/stripe-2.57.0.ebuild (limited to 'dev-python/stripe') diff --git a/dev-python/stripe/Manifest b/dev-python/stripe/Manifest index 5bbcd3e3c876..58d3558e3ddf 100644 --- a/dev-python/stripe/Manifest +++ b/dev-python/stripe/Manifest @@ -1,3 +1,5 @@ DIST stripe-2.56.0.tar.gz 216066 BLAKE2B 1473c0b5a0f53cea18120b6234ed7f310c3625592423f16e77ca3a87c8a79f61c19c0c5f09d071a2be84e4f0d8b5323cc9f1de2e24a74bd24e557c9eb48b2c38 SHA512 1f2f08b5425ad48df9afc78f574109604319ccfcdb2fba8ca574008de5dadb349eec84d0e6cf532c57218bc8624af9b256a29ef01facb950a3cfd1168d8c2660 +DIST stripe-2.57.0.tar.gz 216286 BLAKE2B 9f2c3b7d4ae3f100647a1cae32d09f258703890eb97637ab2a9d3fc1d2fc30eae7042e4245d8f62a5cb4a5226337a7b22813d992842326aaa57d7ecb3a1da200 SHA512 c63efabc8febe79a01167ad4c166d9498f8623a3b1d36c292a3554cbacfc6aada1bf5ec720723b5a9de6e5c4fb770b8f44d1c95289aff4394a70a0301df61e93 EBUILD stripe-2.56.0.ebuild 1720 BLAKE2B a9d99433b7d151404034b4f8f8e54f4fe48bf54235a337bc2d682ee6b4f622f2765ac8caecf82c42fc185fcb16f428de12670bd8af6de839658c8a52a3158a3c SHA512 90bad27eaa41834eab73abfd0d2d8093335854df0758d7d01a52f97d1dbd03195b0ae430f60f5efa7427ce161b31a2ea10c6fcae0c521b8e735b584671219aa7 +EBUILD stripe-2.57.0.ebuild 1722 BLAKE2B c94800d5bb0cb03e31a9b897eff15cf76b2e2a922740346103e4ac62b4ceedf6b282999ca4b4a98b74b817eae9af22e07cd8790aae203941c3ac5e8dc2f99029 SHA512 efd8a8afa15e7187ddedb17c1b6e4b52f44493bf0766ccf0df2dad28ec3651b78f8475a1a39fb0af9f0c332fd971d5bf41bc2c400403cf83af9b2d2318234138 MISC metadata.xml 347 BLAKE2B 864b8bb1a2e79187e4ad90b1377591685a989619a955f7c85eccb80d918b6a03977ecaac744abae18408b97fabf8a205035e941f967a94d6ddbd550de05484f2 SHA512 9f18753a3d3a452f3d0423af1f10fbf476a5a9ae4a70ce4131eb9beab30fc5475dcf18437532a4ad386d780411ac5a00156a1d818348ae7f4eba2fbad5d191cd diff --git a/dev-python/stripe/stripe-2.57.0.ebuild b/dev-python/stripe/stripe-2.57.0.ebuild new file mode 100644 index 000000000000..3895e0af78a6 --- /dev/null +++ b/dev-python/stripe/stripe-2.57.0.ebuild @@ -0,0 +1,63 @@ +# Copyright 1999-2021 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=7 + +PYTHON_COMPAT=( python3_{7..9} pypy3 ) +inherit distutils-r1 + +DESCRIPTION="Stripe python bindings" +HOMEPAGE="https://github.com/stripe/stripe-python" +SRC_URI="mirror://pypi/s/${PN}/${P}.tar.gz" + +LICENSE="MIT" +SLOT="0" +KEYWORDS="~amd64 ~x86" + +RDEPEND=" + >=dev-python/requests-2.20[${PYTHON_USEDEP}] +" +DEPEND=" + test? ( + ${RDEPEND} + >=dev-util/stripe-mock-0.103.0 + dev-python/pytest-mock[${PYTHON_USEDEP}] + net-misc/curl + ) +" + +distutils_enable_tests pytest + +DOCS=(LONG_DESCRIPTION.rst CHANGELOG.md README.md) + +src_test() { + local stripe_mock_port=12111 + local stripe_mock_max_port=12121 + local stripe_mock_logfile="${T}/stripe_mock_${EPYTHON}.log" + # Try to start stripe-mock until we find a free port + while [[ "${stripe_mock_port}" -le "${stripe_mock_max_port}" ]]; do + ebegin "Trying to start stripe-mock on port ${stripe_mock_port}" + stripe-mock --http-port ${stripe_mock_port} &> "${stripe_mock_logfile}" & + local stripe_mock_pid=$! + sleep 2 + # Did stripe-mock start? + curl --fail -u "sk_test_123:" \ + http://127.0.0.1:${stripe_mock_port}/v1/customers &> /dev/null + eend $? "Port ${stripe_mock_port} unavailable" + if [[ $? -eq 0 ]]; then + einfo "stripe-mock running on port ${stripe_mock_port}" + break + fi + (( stripe_mock_port++ )) + done + if [[ "${stripe_mock_port}" -gt "${stripe_mock_max_port}" ]]; then + eerror "Unable to start stripe-mock for tests" + die "Please see the logfile located at: ${stripe_mock_logfile}" + fi + + local -x STRIPE_MOCK_PORT=${stripe_mock_port} + distutils-r1_src_test + + # Tear down stripe-mock + kill "${stripe_mock_pid}" || die "Unable to stop stripe-mock" +} -- cgit v1.2.3