diff options
author | Tiziano Müller <dev-zero@gentoo.org> | 2016-09-13 14:47:04 +0200 |
---|---|---|
committer | Tiziano Müller <dev-zero@gentoo.org> | 2016-09-13 14:53:22 +0200 |
commit | 6f00b983e678b186d0bb207eab8a77c366ba513d (patch) | |
tree | 5da8f8927655cfdc753f5f56670262e704db557a /dev-python/flask-login | |
parent | dev-python/flask-mail: rev-bump for EAPI 6 bump and py-3.5 support (diff) | |
download | gentoo-6f00b983e678b186d0bb207eab8a77c366ba513d.tar.gz gentoo-6f00b983e678b186d0bb207eab8a77c366ba513d.tar.bz2 gentoo-6f00b983e678b186d0bb207eab8a77c366ba513d.zip |
dev-python/flask-login: rev-bump for EAPI 6 bump, py-3.5 support and working tests
This also uses a new tarball since the one from pypi lacks tests
Package-Manager: portage-2.3.0
Diffstat (limited to 'dev-python/flask-login')
-rw-r--r-- | dev-python/flask-login/Manifest | 1 | ||||
-rw-r--r-- | dev-python/flask-login/files/flask-login-0.3.2-fix-tests-python2.patch | 29 | ||||
-rw-r--r-- | dev-python/flask-login/flask-login-0.3.2-r1.ebuild | 34 |
3 files changed, 64 insertions, 0 deletions
diff --git a/dev-python/flask-login/Manifest b/dev-python/flask-login/Manifest index 88fc27a99404..86117e4154cf 100644 --- a/dev-python/flask-login/Manifest +++ b/dev-python/flask-login/Manifest @@ -1,2 +1,3 @@ DIST Flask-Login-0.2.11.tar.gz 11099 SHA256 83d5f10e5c4f214feed6cc41c212db63a58a15ac32e56df81591bfa0a5cee3e5 SHA512 7a9f8a782d182255f5e96a53c5d3a13479b5bac5f8d4af75b7407e3d5f4854cc7b54aa0ff46b29701c050d99de159cea04fff22dea762391447ffefdb7059905 WHIRLPOOL 7f2147d2966ec8a53b4b30a01778336e7e7934fe48bc17009efedfdd05a76b90926622b1917e2ea23599907984eb6683e5f701e7101ce42dce8743e1a65c2038 DIST Flask-Login-0.3.2.tar.gz 11799 SHA256 e72eff5c35e5a31db1aeca1db5d2501be702674ea88e8f223b5d2b11644beee6 SHA512 8465976e5e5350732768a4e34661609e3039d34825265d1af8808e4573f6be276338305a141966be7923f6d898df0be7617f2cff4c65471c336d1ef4b8f37788 WHIRLPOOL 11188b6e364f817fd1ba81fbe401a2bb853148384945130545f6ed8bdd9b9291bdb051a42f55672881064420ddca242efde2e5b456ae8927a749c22fb1db883e +DIST flask-login-0.3.2.tar.gz 38626 SHA256 e7c021eba4f9fb9805e08403a6ee36ce5c7e747e799cc56212bf6c14fce72911 SHA512 c42af6ed7902145cc4778815f247ed88de6df7c929abe0a1f22aca0515495a54d298b2af2b74ba7d5e0ce9b453eee4c4ce03802a3e9ab531137e117e9dcdfc1b WHIRLPOOL 60dacd8c4bec1f96dd934109ecf6517350d5722e2ad1e98524f83d3ac15db4d4329eb05e91f5d78c6664fd54fce8288f70e1157cb53d770816142f7278788675 diff --git a/dev-python/flask-login/files/flask-login-0.3.2-fix-tests-python2.patch b/dev-python/flask-login/files/flask-login-0.3.2-fix-tests-python2.patch new file mode 100644 index 000000000000..33811abdc7ac --- /dev/null +++ b/dev-python/flask-login/files/flask-login-0.3.2-fix-tests-python2.patch @@ -0,0 +1,29 @@ +diff --git a/test_login.py b/test_login.py +index 3f110e0..0c060f5 100644 +--- a/test_login.py ++++ b/test_login.py +@@ -39,6 +39,7 @@ from flask.ext.login import (LoginManager, UserMixin, AnonymousUserMixin, + if str is not bytes: + unicode = str + ++werkzeug_version = tuple(int(i) for i in werkzeug_version.split('.')) + + @contextmanager + def listen_to(signal): +@@ -1073,14 +1074,14 @@ class LoginTestCase(unittest.TestCase): + # + # Misc + # +- @unittest.skipIf(werkzeug_version.startswith("0.9"), ++ @unittest.skipIf(werkzeug_version >= (0, 9), + "wait for upstream implementing RFC 5987") + def test_chinese_user_agent(self): + with self.app.test_client() as c: + result = c.get('/', headers=[('User-Agent', u'中文')]) + self.assertEqual(u'Welcome!', result.data.decode('utf-8')) + +- @unittest.skipIf(werkzeug_version.startswith("0.9"), ++ @unittest.skipIf(werkzeug_version >= (0, 9), + "wait for upstream implementing RFC 5987") + def test_russian_cp1251_user_agent(self): + with self.app.test_client() as c: diff --git a/dev-python/flask-login/flask-login-0.3.2-r1.ebuild b/dev-python/flask-login/flask-login-0.3.2-r1.ebuild new file mode 100644 index 000000000000..f0451faa433b --- /dev/null +++ b/dev-python/flask-login/flask-login-0.3.2-r1.ebuild @@ -0,0 +1,34 @@ +# Copyright 1999-2016 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Id$ + +EAPI=6 +PYTHON_COMPAT=( python2_7 python3_{4,5} pypy ) + +inherit distutils-r1 + +DESCRIPTION="Login session support for Flask" +HOMEPAGE="https://pypi.python.org/pypi/Flask-Login" +SRC_URI="https://github.com/maxcountryman/${PN}/archive/${PV}.tar.gz -> ${P}.tar.gz" +# pypi tarball is missing tests + +LICENSE="BSD" +SLOT="0" +KEYWORDS="~amd64 ~x86" +IUSE="test" + +RDEPEND=">=dev-python/flask-0.10[${PYTHON_USEDEP}]" +DEPEND="${RDEPEND} + dev-python/setuptools[${PYTHON_USEDEP}] + test? ( + dev-python/nose[${PYTHON_USEDEP}] + dev-python/mock[${PYTHON_USEDEP}] + dev-python/blinker[${PYTHON_USEDEP}] + $(python_gen_cond_dep 'dev-python/unittest2[${PYTHON_USEDEP}]' 'python2*' pypy) + )" + +PATCHES=( "${FILESDIR}/${P}-fix-tests-python2.patch" ) + +python_test() { + nosetests -v || die "Tests fail with ${EPYTHON}" +} |