summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJustin Lecher <jlec@gentoo.org>2015-11-03 12:37:36 +0100
committerJustin Lecher <jlec@gentoo.org>2015-11-03 12:38:00 +0100
commitd85169c4e4bf3400c5d2cd2687a0940cb1326152 (patch)
treedf1c023624d8f6bc81884632bedb2238dea09124
parentdev-python/webob: Version Bump (diff)
downloadgentoo-d85169c4e4bf3400c5d2cd2687a0940cb1326152.tar.gz
gentoo-d85169c4e4bf3400c5d2cd2687a0940cb1326152.tar.bz2
gentoo-d85169c4e4bf3400c5d2cd2687a0940cb1326152.zip
dev-python/redis-py: Version Bump
Package-Manager: portage-2.2.23 Signed-off-by: Justin Lecher <jlec@gentoo.org>
-rw-r--r--dev-python/redis-py/Manifest1
-rw-r--r--dev-python/redis-py/files/redis-py-2.10.5-test-backport.patch24
-rw-r--r--dev-python/redis-py/files/redis-py-2.10.5-test-finalize.patch19
-rw-r--r--dev-python/redis-py/redis-py-2.10.5.ebuild66
4 files changed, 110 insertions, 0 deletions
diff --git a/dev-python/redis-py/Manifest b/dev-python/redis-py/Manifest
index 30cc386d5501..c30dc91d36cb 100644
--- a/dev-python/redis-py/Manifest
+++ b/dev-python/redis-py/Manifest
@@ -1,4 +1,5 @@
DIST redis-py-2.10.1.tar.gz 84143 SHA256 644aaf429e666d2254143a6a02f3b1cca2806d0cd52bb130c8f879d3c8259d62 SHA512 694a687e22654631fcf7b0b5884c2f3b3f804befe8080a1a27f08e212afe2f64c36921e025801d67bac1786b105f23565f52768f5b62ed1d18038be8dba9542c WHIRLPOOL e1b76cf47043d3d5317fc4352c9b52598af119a1501e4d6af1615181006afa658417002fdd8e206e6d5d5556df6dcbdd34a74b89918c513802793bd6ced4cccd
DIST redis-py-2.10.3.tar.gz 86532 SHA256 a4fb37b02860f6b1617f6469487471fd086dd2d38bbce640c2055862b9c4019c SHA512 a6dcb1160f91c444a6fd107761b2701e7d8ab2eed7b9fcc00e8f0bdcefe46c2a626611f36fe6bf520fe3cceeb509562609e6dba263e1508abe285a6eab73963c WHIRLPOOL 2b2fc577ff752f71675cade7c591442526dfbac07495d1cf61b14ac21371e76aec2d008531bb8729eb5e3f3ffd372d6c9bf9f7554e51f8076d2d79c07377d33e
+DIST redis-py-2.10.5.tar.gz 88610 SHA256 5dfbae6acfc54edf0a7a415b99e0b21c0a3c27a7f787b292eea727b1facc5533 SHA512 b2e6cb85c274c8f1c63e27256bbab816d016a68c324bf7092cf53feae819a34fa94f45565b0f209ee981919d793b2963462eb1a6f841e9dde9885802e0ebbe8f WHIRLPOOL af0b92b5ddb69346ff285d959a5052df5d65638e70d8d1b3d4b00adb80755eef41b492bfea432507443883f206a4537faf10e82d4253d7612e74ab7a52df47f1
DIST redis-py-2.7.4.tar.gz 79715 SHA256 623c8d437401314f8ec92f03848638c79c757098b316f0ed40ec2deaad57e082 SHA512 9b8db28c77e9df7a243e510a4f66a021179ab8ff52cfed2cc1b18b20f167eeee138d59a868fc105a32993681551c53e98d45680c16313680e8b4f36b6defa3b9 WHIRLPOOL fa5c754dc83f7d8baea68e21e283435994380e3e7243fa9bdb74ce934f7adacc75a11c6312d4b642606aa817010abc23f8f2a7b9eac1e2c73e50e897085124ad
DIST redis-py-2.9.1.tar.gz 62204 SHA256 af9747ec2727425b1b09252975e21502ee5a3d8d235c7f49869eb13e09ccf4e4 SHA512 6b4912acafb31c87a5bc47b0420834aa9d1eba57feb0bbacdea943b746fe2f24aee4c9f13e7b03ae4edc562043b22c370cc7f53e45be07c5408cfa9852f8ea38 WHIRLPOOL ae38ea63d605f8dd667d9fc548de972bf38d661ae6ef357070ebe7cba3b484febc45d6b7611916d8a1e262e6bbf4754257e727f41af8caa30597954a1fc20cf5
diff --git a/dev-python/redis-py/files/redis-py-2.10.5-test-backport.patch b/dev-python/redis-py/files/redis-py-2.10.5-test-backport.patch
new file mode 100644
index 000000000000..74d2d14134d5
--- /dev/null
+++ b/dev-python/redis-py/files/redis-py-2.10.5-test-backport.patch
@@ -0,0 +1,24 @@
+From 550eee8106ca5984f104b3a2a79299d9ae0821af Mon Sep 17 00:00:00 2001
+From: Chris Lamb <chris@chris-lamb.co.uk>
+Date: Tue, 18 Aug 2015 13:28:40 +0200
+Subject: [PATCH] Fix tests under Redis 3.x; we can be of an "embedded string"
+ format now.
+
+Signed-off-by: Chris Lamb <chris@chris-lamb.co.uk>
+---
+ tests/test_commands.py | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/tests/test_commands.py b/tests/test_commands.py
+index 2e104ed..c0e56b0 100644
+--- a/tests/test_commands.py
++++ b/tests/test_commands.py
+@@ -112,7 +112,7 @@ def test_object(self, r):
+ r['a'] = 'foo'
+ assert isinstance(r.object('refcount', 'a'), int)
+ assert isinstance(r.object('idletime', 'a'), int)
+- assert r.object('encoding', 'a') == b('raw')
++ assert r.object('encoding', 'a') in (b('raw'), b('embstr'))
+ assert r.object('idletime', 'invalid-key') is None
+
+ def test_ping(self, r):
diff --git a/dev-python/redis-py/files/redis-py-2.10.5-test-finalize.patch b/dev-python/redis-py/files/redis-py-2.10.5-test-finalize.patch
new file mode 100644
index 000000000000..1a807480dfb0
--- /dev/null
+++ b/dev-python/redis-py/files/redis-py-2.10.5-test-finalize.patch
@@ -0,0 +1,19 @@
+ setup.py | 5 -----
+ 1 file changed, 5 deletions(-)
+
+diff --git a/setup.py b/setup.py
+index ed8fd5f..ab648a3 100644
+--- a/setup.py
++++ b/setup.py
+@@ -9,11 +9,6 @@ try:
+ from setuptools.command.test import test as TestCommand
+
+ class PyTest(TestCommand):
+- def finalize_options(self):
+- TestCommand.finalize_options(self)
+- self.test_args = []
+- self.test_suite = True
+-
+ def run_tests(self):
+ # import here, because outside the eggs aren't loaded
+ import pytest
diff --git a/dev-python/redis-py/redis-py-2.10.5.ebuild b/dev-python/redis-py/redis-py-2.10.5.ebuild
new file mode 100644
index 000000000000..cfc6a77ff507
--- /dev/null
+++ b/dev-python/redis-py/redis-py-2.10.5.ebuild
@@ -0,0 +1,66 @@
+# Copyright 1999-2015 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI=5
+
+PYTHON_COMPAT=( python2_7 python3_{3,4,5} pypy pypy3 )
+
+inherit distutils-r1
+
+MY_PN="redis"
+MY_P="${MY_PN}-${PV}"
+
+DESCRIPTION="Python client for Redis key-value store"
+HOMEPAGE="https://github.com/andymccurdy/redis-py"
+SRC_URI="mirror://pypi/${MY_PN:0:1}/${MY_PN}/${MY_P}.tar.gz -> ${P}.tar.gz"
+
+LICENSE="MIT"
+SLOT="0"
+KEYWORDS="~amd64 ~arm ~hppa ~ppc64 ~x86 ~amd64-linux ~x86-linux"
+IUSE="test"
+
+RDEPEND=""
+DEPEND="dev-python/setuptools[${PYTHON_USEDEP}]
+ test? ( dev-db/redis
+ >=dev-python/pytest-2.5.0[${PYTHON_USEDEP}] )"
+
+S="${WORKDIR}/${MY_P}"
+
+PATCHES=(
+ "${FILESDIR}"/${P}-test-finalize.patch
+)
+
+python_prepare_all() {
+ distutils-r1_python_prepare_all
+
+ # Make sure that tests will be used from BUILD_DIR rather than cwd.
+ mv tests tests-hidden || die
+
+ # Correct local import patch syntax
+ sed -e 's:from .conftest:from conftest:' \
+ -i tests-hidden/{test_connection_pool.py,test_commands.py,test_encoding.py,test_pubsub.py} \
+ || die
+}
+
+python_compile() {
+ distutils-r1_python_compile
+
+ if use test; then
+ cp -r tests-hidden "${BUILD_DIR}"/tests || die
+ fi
+}
+
+python_test() {
+ local sock="${T}/redis.sock"
+
+ "${EPREFIX}/usr/sbin/redis-server" - <<- EOF
+ daemonize yes
+ pidfile "${T}/redis.pid"
+ unixsocket ${sock}
+ EOF
+
+ PYTHONPATH="${S}:${S}/tests-hidden"
+ esetup.py test --verbose
+ kill $(<"${T}/redis.pid")
+}