summaryrefslogtreecommitdiff
path: root/dev-python/flask-login
diff options
context:
space:
mode:
Diffstat (limited to 'dev-python/flask-login')
-rw-r--r--dev-python/flask-login/Manifest3
-rw-r--r--dev-python/flask-login/files/flask-login-0.5.0-fix-tests-py3.10.patch26
-rw-r--r--dev-python/flask-login/flask-login-0.5.0.ebuild8
3 files changed, 34 insertions, 3 deletions
diff --git a/dev-python/flask-login/Manifest b/dev-python/flask-login/Manifest
index eef74a63775f..08fe935da0d9 100644
--- a/dev-python/flask-login/Manifest
+++ b/dev-python/flask-login/Manifest
@@ -1,3 +1,4 @@
+AUX flask-login-0.5.0-fix-tests-py3.10.patch 769 BLAKE2B 82cfe4209de45f6c282b3e289daca11f31ecd96764eba7185909f8d7896e9e39e4401ab7e250155d07575a779bf98f836a7ffcb7d47ae1a1cb6f35f342fd86d4 SHA512 04f0cdf5b6beac3ecbc27513fd994362416c6990f9040710f979b997cace59d7560e4a0471b44e04f9de69fa93ac8698a0c73765f7548f1adc9ddaf5de834e4d
DIST flask-login-0.5.0.tar.gz 44961 BLAKE2B a780a3ca1ced7f01cbc1f99e3d92f57819c73982a4098330be7b9b4dce88e5fac577d15b2989b99971c4b2f7e6c9f02a54aeab9f7fa1c101f409cbdcfa3c6942 SHA512 8ffecd2a512738f81ec3901ad30d356b1d63355268f7cf1b427e463d0a271a4623723255e139bbd0f88845d73fa4aab051418b5f68aef0b4576c30294f6207b3
-EBUILD flask-login-0.5.0.ebuild 938 BLAKE2B 98355a765627fd33ed34af7bebee654140ed076b79e6c7614ba0c927dc014f6e0e764ee4a20b517b0417495d61285b02be1c8bcd9d31d41974a8daf5e28e61b4 SHA512 a8e401b4ac25170c90c54ae029c2a1169a05c443b39546b048ac5205437d09ec4a954e83ea63f72e4ac030b7a74470e2ebe0fd1b56a6f12c24c7fcc909317fc3
+EBUILD flask-login-0.5.0.ebuild 954 BLAKE2B 1161426afa0c97cc1130859296c56155a09cf0cc1cfe928f515b06060cafa036e4872c5f23eca25300d98f6fafa8cf933710159932ba9770b5fd99e64834ba5c SHA512 a2ced124a7b1169cb8fbb77089e2cec3f2e4ae62a9e6c42da4627c0d357224c75c846fdf3630f78857e00e090900b243b55f9d1b11c0dcdd134796b11136b92f
MISC metadata.xml 403 BLAKE2B 6d3c96df8b0f4b87c4b08c55049c64e75d953228b7070f1fe9fce68f5c3cbc824d2d3d8430916678596102cf04b9493243a6c9d18d0c2e99eb2ffd24e63229b6 SHA512 151fcb723bb00f89e28147c2635a23834eac59fe2fccd250da22f386f897419071b31fde15f41289d48343803a7a6f1a14236c796c1772dca5f3a947c66a3d96
diff --git a/dev-python/flask-login/files/flask-login-0.5.0-fix-tests-py3.10.patch b/dev-python/flask-login/files/flask-login-0.5.0-fix-tests-py3.10.patch
new file mode 100644
index 000000000000..858783b36e77
--- /dev/null
+++ b/dev-python/flask-login/files/flask-login-0.5.0-fix-tests-py3.10.patch
@@ -0,0 +1,26 @@
+From: Karthikeyan Singaravelan <tir.karthi@gmail.com>
+Date: Sun, 10 Jan 2021 21:12:36 +0530
+Subject: [PATCH] Import ABC from collections.abc (#525)
+
+--- a/test_login.py
++++ b/test_login.py
+@@ -12,6 +12,10 @@
+ from mock import ANY, patch, Mock
+ except ImportError:
+ from unittest.mock import ANY, patch, Mock
++try:
++ from collections.abc import Hashable
++except ImportError:
++ from collections import Hashable
+ from semantic_version import Version
+
+
+@@ -1548,7 +1552,7 @@ def test_equality(self):
+ self.assertTrue(first != u'1')
+
+ def test_hashable(self):
+- self.assertTrue(isinstance(UserMixin(), collections.Hashable))
++ self.assertTrue(isinstance(UserMixin(), Hashable))
+
+
+ class AnonymousUserTestCase(unittest.TestCase):
diff --git a/dev-python/flask-login/flask-login-0.5.0.ebuild b/dev-python/flask-login/flask-login-0.5.0.ebuild
index 3891e82cb9d3..b23911bf5684 100644
--- a/dev-python/flask-login/flask-login-0.5.0.ebuild
+++ b/dev-python/flask-login/flask-login-0.5.0.ebuild
@@ -3,7 +3,7 @@
EAPI=7
-PYTHON_COMPAT=( python3_{7..9} )
+PYTHON_COMPAT=( python3_{8..10} )
inherit distutils-r1
DESCRIPTION="Login session support for Flask"
@@ -27,9 +27,13 @@ DEPEND="
dev-python/semantic_version[${PYTHON_USEDEP}]
)"
+PATCHES=(
+ "${FILESDIR}/${P}-fix-tests-py3.10.patch"
+)
+
distutils_enable_sphinx docs
distutils_enable_tests pytest
python_test() {
- pytest -vv -p no:httpbin || die "Tests failed with ${EPYTHON}"
+ epytest -p no:httpbin
}