forked from pld-linux/python3
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathpython3-tests.patch
More file actions
22 lines (18 loc) · 1002 Bytes
/
python3-tests.patch
File metadata and controls
22 lines (18 loc) · 1002 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
diff -urNp -x '*.orig' Python-3.9.2.org/Lib/test/test_imaplib.py Python-3.9.2/Lib/test/test_imaplib.py
--- Python-3.9.2.org/Lib/test/test_imaplib.py 2021-02-19 13:31:44.000000000 +0100
+++ Python-3.9.2/Lib/test/test_imaplib.py 2021-02-25 18:42:23.540101637 +0100
@@ -74,7 +74,7 @@ class TestImaplib(unittest.TestCase):
def test_imap4_host_default_value(self):
# Check whether the IMAP4_PORT is truly unavailable.
- with socket.socket() as s:
+ with socket.socket(socket.AF_INET, socket.SOCK_STREAM) as s:
try:
s.connect(('', imaplib.IMAP4_PORT))
self.skipTest(
@@ -85,7 +85,7 @@ class TestImaplib(unittest.TestCase):
# This is the exception that should be raised.
expected_errnos = socket_helper.get_socket_conn_refused_errs()
with self.assertRaises(OSError) as cm:
- imaplib.IMAP4()
+ imaplib.IMAP4('0.0.0.0')
self.assertIn(cm.exception.errno, expected_errnos)