summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLouis Sautier <sbraz@gentoo.org>2022-11-26 20:18:05 +0100
committerLouis Sautier <sbraz@gentoo.org>2022-11-26 23:10:50 +0100
commit0083001fd7b5dc20f3334b356707b08e016bda16 (patch)
treea7e23d7abad98847b8b400db691f57bcb9fef67c /dev-python/httpauth/files/httpauth-0.3-remove-nose-dependency.patch
parentsys-apps/portage: warn about obsolete enotice in profile.bashrc (diff)
downloadgentoo-0083001fd7b5dc20f3334b356707b08e016bda16.tar.gz
gentoo-0083001fd7b5dc20f3334b356707b08e016bda16.tar.bz2
gentoo-0083001fd7b5dc20f3334b356707b08e016bda16.zip
dev-python/httpauth: enable py3.11, drop nose
Signed-off-by: Louis Sautier <sbraz@gentoo.org>
Diffstat (limited to 'dev-python/httpauth/files/httpauth-0.3-remove-nose-dependency.patch')
-rw-r--r--dev-python/httpauth/files/httpauth-0.3-remove-nose-dependency.patch40
1 files changed, 40 insertions, 0 deletions
diff --git a/dev-python/httpauth/files/httpauth-0.3-remove-nose-dependency.patch b/dev-python/httpauth/files/httpauth-0.3-remove-nose-dependency.patch
new file mode 100644
index 000000000000..5cb607c2bb4c
--- /dev/null
+++ b/dev-python/httpauth/files/httpauth-0.3-remove-nose-dependency.patch
@@ -0,0 +1,40 @@
+commit d57060ebaeca8cd38e03cc64f9ee0996e83b50a9
+Author: Jonas Haag <jonas@lophus.org>
+Date: Thu Apr 21 08:58:36 2022 +0200
+
+ Move CI to GHA (#3)
+
+--- a/tests.py
++++ b/tests.py
+@@ -10,7 +10,7 @@ except ImportError: # Python 2
+
+ from httpauth import DictHttpAuthMiddleware, DigestFileHttpAuthMiddleware, md5_str
+
+-from nose.tools import raises
++import pytest
+
+
+ def parse_dict_header(value):
+@@ -121,16 +121,16 @@ def test_without_realm():
+ assert 'Digest realm=""' in response.headers['WWW-Authenticate']
+
+
+-@raises(ValueError)
+ def test_invalid_digestfile_1():
+- DigestFileHttpAuthMiddleware(StringIO('u::realm:hash'),
+- wsgi_app=wsgi_app)
++ with pytest.raises(ValueError):
++ DigestFileHttpAuthMiddleware(StringIO('u::realm:hash'),
++ wsgi_app=wsgi_app)
+
+
+-@raises(ValueError)
+ def test_invalid_digestfile_2():
+- DigestFileHttpAuthMiddleware(StringIO('u:realm:hash\nu2:realm2:hash2'),
+- wsgi_app=wsgi_app)
++ with pytest.raises(ValueError):
++ DigestFileHttpAuthMiddleware(StringIO('u:realm:hash\nu2:realm2:hash2'),
++ wsgi_app=wsgi_app)
+
+
+ def test_ticket_1():