repo_id
stringclasses
400 values
cross_repo_split
stringclasses
1 value
commit_index
int32
0
1.19k
commit_sha
stringlengths
40
40
in_repo_split
stringclasses
3 values
test_file
stringlengths
7
121
file_split
stringclasses
3 values
split_group
stringlengths
18
150
lineno
int32
1
5.24k
col_offset
int32
0
165
assertion_type
stringclasses
35 values
test_function
stringlengths
0
141
prefix
large_stringlengths
7
258k
target
stringlengths
1
29.2k
assertion_event_type
stringclasses
2 values
assertion_event_id
stringlengths
64
64
assertion_anchor
large_stringlengths
14
176k
old_target
stringlengths
1
11.2k
old_lineno
int32
2
4.91k
old_col_offset
int32
0
165
urllib3/urllib3
train
73
951ea12ba18103e5434e751246c0895e54fef211
train
test/with_dummyserver/test_proxy_poolmanager.py
train
urllib3/urllib3:test/with_dummyserver/test_proxy_poolmanager.py
129
8
self.assertNotEqual
test_cross_host_redirect
import unittest import json import socket from dummyserver.testcase import HTTPDummyProxyTestCase from dummyserver.server import DEFAULT_CA, DEFAULT_CA_BAD from urllib3.poolmanager import proxy_from_url, ProxyManager from urllib3.exceptions import MaxRetryError, SSLError, ProxyError from urllib3.connectionpool import...
self.http_host_alt)
added
b685cf3e8d59e5125fbbbca38419eee6c253c1597e20aa59d5b56e5f187a1fcb
self.assertNotEqual|test_cross_host_redirect|import unittest import json import socket from dummyserver.testcase import HTTPDummyProxyTestCase from dummyserver.server import DEFAULT_CA, DEFAULT_CA_BAD from urllib3.poolmanager import proxy_from_url, ProxyManager from urllib3.exceptions import MaxRetryError, SSLError, Pr...
null
null
null
urllib3/urllib3
train
74
5b587a610bba8d70e0e9ee3be2d4dc5e08303309
train
test/with_dummyserver/test_proxy_poolmanager.py
train
urllib3/urllib3:test/with_dummyserver/test_proxy_poolmanager.py
71
12
self.assertTrue
test_proxy_verified
import unittest import json import socket from dummyserver.testcase import HTTPDummyProxyTestCase from dummyserver.server import ( DEFAULT_CA, DEFAULT_CA_BAD, get_unreachable_address) from urllib3.poolmanager import proxy_from_url, ProxyManager from urllib3.exceptions import MaxRetryError, SSLError, ProxyError fr...
'certificate verify failed' in str(e))
added
34d652528ec7b8ccdb054b224e11090bda1082fae1262c85856cb3406c91e133
self.assertTrue|test_proxy_verified|import unittest import json import socket from dummyserver.testcase import HTTPDummyProxyTestCase from dummyserver.server import ( DEFAULT_CA, DEFAULT_CA_BAD, get_unreachable_address) from urllib3.poolmanager import proxy_from_url, ProxyManager from urllib3.exceptions import MaxRetry...
null
null
null
urllib3/urllib3
train
74
5b587a610bba8d70e0e9ee3be2d4dc5e08303309
train
test/with_dummyserver/test_proxy_poolmanager.py
train
urllib3/urllib3:test/with_dummyserver/test_proxy_poolmanager.py
107
8
self.assertEqual
test_redirect
import unittest import json import socket from dummyserver.testcase import HTTPDummyProxyTestCase from dummyserver.server import ( DEFAULT_CA, DEFAULT_CA_BAD, get_unreachable_address) from urllib3.poolmanager import proxy_from_url, ProxyManager from urllib3.exceptions import MaxRetryError, SSLError, ProxyError fr...
b'Dummy server!')
modified
a4884801005b9f2d04c264fbff71cfef8ca88d3ced1a23a1171abc964804b1b2
self.assertEqual|test_redirect|import unittest import json import socket from dummyserver.testcase import HTTPDummyProxyTestCase from dummyserver.server import ( DEFAULT_CA, DEFAULT_CA_BAD, get_unreachable_address) from urllib3.poolmanager import proxy_from_url, ProxyManager from urllib3.exceptions import MaxRetryError...
200)
110
8
urllib3/urllib3
train
74
5b587a610bba8d70e0e9ee3be2d4dc5e08303309
train
test/with_dummyserver/test_proxy_poolmanager.py
train
urllib3/urllib3:test/with_dummyserver/test_proxy_poolmanager.py
125
8
self.assertNotEqual
test_cross_host_redirect
import unittest import json import socket from dummyserver.testcase import HTTPDummyProxyTestCase from dummyserver.server import ( DEFAULT_CA, DEFAULT_CA_BAD, get_unreachable_address) from urllib3.poolmanager import proxy_from_url, ProxyManager from urllib3.exceptions import MaxRetryError, SSLError, ProxyError fr...
self.http_host_alt)
added
3169a1eed1e8929173c0b144519532c34f1dd5432c1bcef705449dc08bb7448d
self.assertNotEqual|test_cross_host_redirect|import unittest import json import socket from dummyserver.testcase import HTTPDummyProxyTestCase from dummyserver.server import ( DEFAULT_CA, DEFAULT_CA_BAD, get_unreachable_address) from urllib3.poolmanager import proxy_from_url, ProxyManager from urllib3.exceptions import...
null
null
null
urllib3/urllib3
train
74
5b587a610bba8d70e0e9ee3be2d4dc5e08303309
train
test/with_dummyserver/test_proxy_poolmanager.py
train
urllib3/urllib3:test/with_dummyserver/test_proxy_poolmanager.py
205
8
self.assertEqual
test_headers
import unittest import json import socket from dummyserver.testcase import HTTPDummyProxyTestCase from dummyserver.server import ( DEFAULT_CA, DEFAULT_CA_BAD, get_unreachable_address) from urllib3.poolmanager import proxy_from_url, ProxyManager from urllib3.exceptions import MaxRetryError, SSLError, ProxyError fr...
'%s:%s'%(self.http_host,self.http_port))
modified
198cf19a3167f35dd8b0dd3bb5b47e09169d9b24c899dc5c9f756d2d582a8d99
self.assertEqual|test_headers|import unittest import json import socket from dummyserver.testcase import HTTPDummyProxyTestCase from dummyserver.server import ( DEFAULT_CA, DEFAULT_CA_BAD, get_unreachable_address) from urllib3.poolmanager import proxy_from_url, ProxyManager from urllib3.exceptions import MaxRetryError,...
'dickory')
208
8
urllib3/urllib3
train
74
5b587a610bba8d70e0e9ee3be2d4dc5e08303309
train
test/with_dummyserver/test_socketlevel.py
train
urllib3/urllib3:test/with_dummyserver/test_socketlevel.py
68
8
self.assertTrue
test_hostname_in_first_request_packet
from urllib3 import HTTPConnectionPool, HTTPSConnectionPool from urllib3.poolmanager import proxy_from_url from urllib3.exceptions import ( MaxRetryError, ProxyError, ReadTimeoutError, SSLError, ) from urllib3 import util from dummyserver.testcase import SocketDummyServerTestCase from ...
self.host.encode() in self.buf)
modified
f14dca27408cf9146c0762f716ce422e344cbad4c0a2c27f64058595b14a4508
self.assertTrue|test_hostname_in_first_request_packet|from urllib3 import HTTPConnectionPool, HTTPSConnectionPool from urllib3.poolmanager import proxy_from_url from urllib3.exceptions import ( MaxRetryError, ProxyError, ReadTimeoutError, SSLError, ) from urllib3 import util from dummyserver.testcase import SocketDummy...
self.host.encode() in self.buf)
67
8
urllib3/urllib3
train
74
5b587a610bba8d70e0e9ee3be2d4dc5e08303309
train
test/with_dummyserver/test_socketlevel.py
train
urllib3/urllib3:test/with_dummyserver/test_socketlevel.py
110
8
self.assertEqual
test_recovery_when_server_closes_connection
from urllib3 import HTTPConnectionPool, HTTPSConnectionPool from urllib3.poolmanager import proxy_from_url from urllib3.exceptions import ( MaxRetryError, ProxyError, ReadTimeoutError, SSLError, ) from urllib3 import util from dummyserver.testcase import SocketDummyServerTestCase from ...
b'Response 1')
modified
fbcc4c9c674fcc5c2d60529a030097d314bd16774ddbc32bf8d53a991a5a3b5d
self.assertEqual|test_recovery_when_server_closes_connection|from urllib3 import HTTPConnectionPool, HTTPSConnectionPool from urllib3.poolmanager import proxy_from_url from urllib3.exceptions import ( MaxRetryError, ProxyError, ReadTimeoutError, SSLError, ) from urllib3 import util from dummyserver.testcase import Sock...
b'Response 1')
109
8
urllib3/urllib3
train
74
5b587a610bba8d70e0e9ee3be2d4dc5e08303309
train
test/with_dummyserver/test_socketlevel.py
train
urllib3/urllib3:test/with_dummyserver/test_socketlevel.py
172
12
self.assertEqual
test_timeout_errors_cause_retries
from urllib3 import HTTPConnectionPool, HTTPSConnectionPool from urllib3.poolmanager import proxy_from_url from urllib3.exceptions import ( MaxRetryError, ProxyError, ReadTimeoutError, SSLError, ) from urllib3 import util from dummyserver.testcase import SocketDummyServerTestCase from ...
b'Response 2')
modified
fdfb4183a5d1a289cdd6fa6907f30206091911f72b8d34dff08cfcf7d6e6f595
self.assertEqual|test_timeout_errors_cause_retries|from urllib3 import HTTPConnectionPool, HTTPSConnectionPool from urllib3.poolmanager import proxy_from_url from urllib3.exceptions import ( MaxRetryError, ProxyError, ReadTimeoutError, SSLError, ) from urllib3 import util from dummyserver.testcase import SocketDummySer...
200)
175
12
urllib3/urllib3
train
74
5b587a610bba8d70e0e9ee3be2d4dc5e08303309
train
test/with_dummyserver/test_socketlevel.py
train
urllib3/urllib3:test/with_dummyserver/test_socketlevel.py
244
8
self.assertTrue
test_headers
from urllib3 import HTTPConnectionPool, HTTPSConnectionPool from urllib3.poolmanager import proxy_from_url from urllib3.exceptions import ( MaxRetryError, ProxyError, ReadTimeoutError, SSLError, ) from urllib3 import util from dummyserver.testcase import SocketDummyServerTestCase from ...
b'For The Proxy: YEAH!\r\n' in r.data)
added
686b3eeae1b43653cae51f0ad1d2fc3489a07c80d1328ff2db91f215fca57f08
self.assertTrue|test_headers|from urllib3 import HTTPConnectionPool, HTTPSConnectionPool from urllib3.poolmanager import proxy_from_url from urllib3.exceptions import ( MaxRetryError, ProxyError, ReadTimeoutError, SSLError, ) from urllib3 import util from dummyserver.testcase import SocketDummyServerTestCase from dummy...
null
null
null
urllib3/urllib3
train
75
094e1070e8acc017e1b8e6139a512b4f4c8c7a18
train
test/with_dummyserver/test_connectionpool.py
train
urllib3/urllib3:test/with_dummyserver/test_connectionpool.py
511
8
self.assertRaises
test_dns_error
import logging import socket import sys import unittest import mock try: from urllib.parse import urlencode except: from urllib import urlencode from urllib3 import ( encode_multipart_formdata, HTTPConnectionPool, ) from urllib3.exceptions import ( ConnectTimeoutError, EmptyPoolError, Dec...
MaxRetryError)
modified
f88e0ede72c24280fcd5aaf8893581f4786ad209af1a53552ae29d5a78dea8c7
self.assertRaises|test_dns_error|import logging import socket import sys import unittest import mock try: from urllib.parse import urlencode except: from urllib import urlencode from urllib3 import ( encode_multipart_formdata, HTTPConnectionPool, ) from urllib3.exceptions import ( ConnectTimeoutError, EmptyPoolError, D...
MaxRetryError)
513
8
urllib3/urllib3
train
76
34f3eb75ac4214fc62c78c8b97916f081552495b
train
test/with_dummyserver/test_connectionpool.py
train
urllib3/urllib3:test/with_dummyserver/test_connectionpool.py
187
8
self.assertRaises
test_connect_timeout
import errno import functools import logging import socket import sys import unittest import mock try: from urllib.parse import urlencode except: from urllib import urlencode from test import requires_network from urllib3 import ( encode_multipart_formdata, HTTPConnectionPool, ) from urllib3.exceptio...
ConnectTimeoutError)
modified
164ea832c25adc588b9fe53e7e472fa78fdcee4a496f7c3df7d008c57492bd92
self.assertRaises|test_connect_timeout|import errno import functools import logging import socket import sys import unittest import mock try: from urllib.parse import urlencode except: from urllib import urlencode from test import requires_network from urllib3 import ( encode_multipart_formdata, HTTPConnectionPool, ) f...
ConnectTimeoutError)
184
8
urllib3/urllib3
train
76
34f3eb75ac4214fc62c78c8b97916f081552495b
train
test/with_dummyserver/test_connectionpool.py
train
urllib3/urllib3:test/with_dummyserver/test_connectionpool.py
392
8
self.assertEqual
test_check_deflate
import errno import functools import logging import socket import sys import unittest import mock try: from urllib.parse import urlencode except: from urllib import urlencode from test import requires_network from urllib3 import ( encode_multipart_formdata, HTTPConnectionPool, ) from urllib3.exceptio...
b'hello, world!')
added
f1d5c061efc1c244ccc53e81d04b7f74f7b8afff99c85dfad907817b361f8f6f
self.assertEqual|test_check_deflate|import errno import functools import logging import socket import sys import unittest import mock try: from urllib.parse import urlencode except: from urllib import urlencode from test import requires_network from urllib3 import ( encode_multipart_formdata, HTTPConnectionPool, ) from...
null
null
null
urllib3/urllib3
train
76
34f3eb75ac4214fc62c78c8b97916f081552495b
train
test/with_dummyserver/test_connectionpool.py
train
urllib3/urllib3:test/with_dummyserver/test_connectionpool.py
399
8
self.assertRaises
test_bad_decode
import errno import functools import logging import socket import sys import unittest import mock try: from urllib.parse import urlencode except: from urllib import urlencode from test import requires_network from urllib3 import ( encode_multipart_formdata, HTTPConnectionPool, ) from urllib3.exceptio...
DecodeError)
added
349ddf7d3baa1b8310d11c9ec90e5edf26b0b64cdf886e7ac8fdd16ae3fb3741
self.assertRaises|test_bad_decode|import errno import functools import logging import socket import sys import unittest import mock try: from urllib.parse import urlencode except: from urllib import urlencode from test import requires_network from urllib3 import ( encode_multipart_formdata, HTTPConnectionPool, ) from u...
null
null
null
urllib3/urllib3
train
76
34f3eb75ac4214fc62c78c8b97916f081552495b
train
test/with_dummyserver/test_connectionpool.py
train
urllib3/urllib3:test/with_dummyserver/test_connectionpool.py
515
8
self.assertRaises
test_dns_error
import errno import functools import logging import socket import sys import unittest import mock try: from urllib.parse import urlencode except: from urllib import urlencode from test import requires_network from urllib3 import ( encode_multipart_formdata, HTTPConnectionPool, ) from urllib3.exceptio...
MaxRetryError)
added
4b25c9dff82ead7b719556fe81a036f4d0fc080c9feb2476ca13ffe62260f21d
self.assertRaises|test_dns_error|import errno import functools import logging import socket import sys import unittest import mock try: from urllib.parse import urlencode except: from urllib import urlencode from test import requires_network from urllib3 import ( encode_multipart_formdata, HTTPConnectionPool, ) from ur...
null
null
null
urllib3/urllib3
train
76
34f3eb75ac4214fc62c78c8b97916f081552495b
train
test/with_dummyserver/test_https.py
train
urllib3/urllib3:test/with_dummyserver/test_https.py
79
12
self.assertRaises
test_no_ssl
import logging import ssl import sys import unittest import mock from dummyserver.testcase import HTTPSDummyServerTestCase from dummyserver.server import DEFAULT_CA, DEFAULT_CA_BAD, DEFAULT_CERTS from test import requires_network from urllib3 import HTTPSConnectionPool from urllib3.connection import ( VerifiedHT...
SSLError)
added
68e865ff2ff18bd52acdd326bd25b8c07e14a60a4640af6f206bf4781598aae4
self.assertRaises|test_no_ssl|import logging import ssl import sys import unittest import mock from dummyserver.testcase import HTTPSDummyServerTestCase from dummyserver.server import DEFAULT_CA, DEFAULT_CA_BAD, DEFAULT_CERTS from test import requires_network from urllib3 import HTTPSConnectionPool from urllib3.connect...
null
null
null
urllib3/urllib3
train
76
34f3eb75ac4214fc62c78c8b97916f081552495b
train
test/with_dummyserver/test_https.py
train
urllib3/urllib3:test/with_dummyserver/test_https.py
109
8
self.assertRaises
test_cert_reqs_as_short_string
import logging import ssl import sys import unittest import mock from dummyserver.testcase import HTTPSDummyServerTestCase from dummyserver.server import DEFAULT_CA, DEFAULT_CA_BAD, DEFAULT_CERTS from test import requires_network from urllib3 import HTTPSConnectionPool from urllib3.connection import ( VerifiedHT...
SSLError)
added
7f500004249e2b8433a775f1370979ac2d6cd633b5d7dd164f56c2f3f17cf297
self.assertRaises|test_cert_reqs_as_short_string|import logging import ssl import sys import unittest import mock from dummyserver.testcase import HTTPSDummyServerTestCase from dummyserver.server import DEFAULT_CA, DEFAULT_CA_BAD, DEFAULT_CERTS from test import requires_network from urllib3 import HTTPSConnectionPool f...
null
null
null
urllib3/urllib3
train
76
34f3eb75ac4214fc62c78c8b97916f081552495b
train
test/with_dummyserver/test_https.py
train
urllib3/urllib3:test/with_dummyserver/test_https.py
131
8
self.assertRaises
test_invalid_ca_certs
import logging import ssl import sys import unittest import mock from dummyserver.testcase import HTTPSDummyServerTestCase from dummyserver.server import DEFAULT_CA, DEFAULT_CA_BAD, DEFAULT_CERTS from test import requires_network from urllib3 import HTTPSConnectionPool from urllib3.connection import ( VerifiedHT...
SSLError)
added
65d11916122b1a74e02b17d756a489cfc7a3cc779e0990b9678713416108b114
self.assertRaises|test_invalid_ca_certs|import logging import ssl import sys import unittest import mock from dummyserver.testcase import HTTPSDummyServerTestCase from dummyserver.server import DEFAULT_CA, DEFAULT_CA_BAD, DEFAULT_CERTS from test import requires_network from urllib3 import HTTPSConnectionPool from urlli...
null
null
null
urllib3/urllib3
train
76
34f3eb75ac4214fc62c78c8b97916f081552495b
train
test/with_dummyserver/test_https.py
train
urllib3/urllib3:test/with_dummyserver/test_https.py
185
8
self.assertRaises
test_assert_invalid_fingerprint
import logging import ssl import sys import unittest import mock from dummyserver.testcase import HTTPSDummyServerTestCase from dummyserver.server import DEFAULT_CA, DEFAULT_CA_BAD, DEFAULT_CERTS from test import requires_network from urllib3 import HTTPSConnectionPool from urllib3.connection import ( VerifiedHT...
SSLError)
modified
09a023c4b783854ba156613850e13855e5643af06c0b9ab1f39e9757e1c50e8a
self.assertRaises|test_assert_invalid_fingerprint|import logging import ssl import sys import unittest import mock from dummyserver.testcase import HTTPSDummyServerTestCase from dummyserver.server import DEFAULT_CA, DEFAULT_CA_BAD, DEFAULT_CERTS from test import requires_network from urllib3 import HTTPSConnectionPool ...
SSLError)
184
8
urllib3/urllib3
train
77
73a451d93645a70b45087894d114972f40120658
train
test/test_collections.py
train
urllib3/urllib3:test/test_collections.py
60
8
self.assertEqual
test_access_ordering
import unittest from urllib3._collections import ( HTTPHeaderDict, RecentlyUsedContainer as Container ) from urllib3.packages import six xrange = six.moves.xrange class TestLRUContainer(unittest.TestCase): def test_maxsize(self): d = Container(5) for i in xrange(5): d[i] = st...
[5, 6, 7, 8, 9])
modified
b2e600ea3270a4d9fb24b9127144643b9fb3ef909c6838300035a6fcc53d3696
self.assertEqual|test_access_ordering|import unittest from urllib3._collections import ( HTTPHeaderDict, RecentlyUsedContainer as Container ) from urllib3.packages import six xrange = six.moves.xrange class TestLRUContainer(unittest.TestCase): def test_maxsize(self): d = Container(5) for i in xrange(5): d[i] = str(i) s...
[5, 6, 7, 8, 9])
57
8
urllib3/urllib3
train
77
73a451d93645a70b45087894d114972f40120658
train
test/test_collections.py
train
urllib3/urllib3:test/test_collections.py
144
8
self.assertTrue
test_copy
import unittest from urllib3._collections import ( HTTPHeaderDict, RecentlyUsedContainer as Container ) from urllib3.packages import six xrange = six.moves.xrange class TestLRUContainer(unittest.TestCase): def test_maxsize(self): d = Container(5) for i in xrange(5): d[i] = st...
self.d is not h)
added
d351ec4ea3444000dba0ae44a41775dd00060ea75abdd78533600dc31654e948
self.assertTrue|test_copy|import unittest from urllib3._collections import ( HTTPHeaderDict, RecentlyUsedContainer as Container ) from urllib3.packages import six xrange = six.moves.xrange class TestLRUContainer(unittest.TestCase): def test_maxsize(self): d = Container(5) for i in xrange(5): d[i] = str(i) self.assertEq...
null
null
null
urllib3/urllib3
train
77
73a451d93645a70b45087894d114972f40120658
train
test/test_collections.py
train
urllib3/urllib3:test/test_collections.py
158
8
self.assertFalse
test_delitem
import unittest from urllib3._collections import ( HTTPHeaderDict, RecentlyUsedContainer as Container ) from urllib3.packages import six xrange = six.moves.xrange class TestLRUContainer(unittest.TestCase): def test_maxsize(self): d = Container(5) for i in xrange(5): d[i] = st...
'a' in self.d)
added
78b8b1451d04a486c797d15960032ea15376fbc3df71761d2d3a377bad8fb067
self.assertFalse|test_delitem|import unittest from urllib3._collections import ( HTTPHeaderDict, RecentlyUsedContainer as Container ) from urllib3.packages import six xrange = six.moves.xrange class TestLRUContainer(unittest.TestCase): def test_maxsize(self): d = Container(5) for i in xrange(5): d[i] = str(i) self.asse...
null
null
null
urllib3/urllib3
train
77
73a451d93645a70b45087894d114972f40120658
train
test/test_response.py
train
urllib3/urllib3:test/test_response.py
358
8
self.assertEqual
test_get_case_insensitive_headers
import unittest from io import BytesIO, BufferedReader from urllib3.response import HTTPResponse from urllib3.exceptions import DecodeError from base64 import b64decode # A known random (i.e, not-too-compressible) payload generated with: # "".join(random.choice(string.printable) for i in xrange(512)) # .enco...
'example.com')
added
528a31e07cdea37bc101afe82f5be8337b9c9f0b19a97a39787ce8278493cef2
self.assertEqual|test_get_case_insensitive_headers|import unittest from io import BytesIO, BufferedReader from urllib3.response import HTTPResponse from urllib3.exceptions import DecodeError from base64 import b64decode # A known random (i.e, not-too-compressible) payload generated with: # "".join(random.choice(string....
null
null
null
urllib3/urllib3
train
77
73a451d93645a70b45087894d114972f40120658
train
test/test_response.py
train
urllib3/urllib3:test/test_response.py
359
8
self.assertEqual
test_get_case_insensitive_headers
import unittest from io import BytesIO, BufferedReader from urllib3.response import HTTPResponse from urllib3.exceptions import DecodeError from base64 import b64decode # A known random (i.e, not-too-compressible) payload generated with: # "".join(random.choice(string.printable) for i in xrange(512)) # .enco...
'example.com')
added
876e3f8d241ed699b654d915e6ae7ab305d5b39a4cdaf5b1b342b5d22582b651
self.assertEqual|test_get_case_insensitive_headers|import unittest from io import BytesIO, BufferedReader from urllib3.response import HTTPResponse from urllib3.exceptions import DecodeError from base64 import b64decode # A known random (i.e, not-too-compressible) payload generated with: # "".join(random.choice(string....
null
null
null
urllib3/urllib3
train
77
73a451d93645a70b45087894d114972f40120658
train
test/with_dummyserver/test_connectionpool.py
train
urllib3/urllib3:test/with_dummyserver/test_connectionpool.py
50
8
self.assertEqual
test_get
import logging import socket import sys import unittest import mock try: from urllib.parse import urlencode except: from urllib import urlencode from test import requires_network, onlyPY3 from urllib3 import ( encode_multipart_formdata, HTTPConnectionPool, ) from urllib3.exceptions import ( Conne...
r.data)
modified
4e8bc7172deefd3fe85b970724a060c08ca571aa42bf3cf0651e4877815a24eb
self.assertEqual|test_get|import logging import socket import sys import unittest import mock try: from urllib.parse import urlencode except: from urllib import urlencode from test import requires_network, onlyPY3 from urllib3 import ( encode_multipart_formdata, HTTPConnectionPool, ) from urllib3.exceptions import ( Co...
r.data)
51
8
urllib3/urllib3
train
77
73a451d93645a70b45087894d114972f40120658
train
test/with_dummyserver/test_connectionpool.py
train
urllib3/urllib3:test/with_dummyserver/test_connectionpool.py
385
8
self.assertEqual
test_check_gzip
import logging import socket import sys import unittest import mock try: from urllib.parse import urlencode except: from urllib import urlencode from test import requires_network, onlyPY3 from urllib3 import ( encode_multipart_formdata, HTTPConnectionPool, ) from urllib3.exceptions import ( Conne...
b'hello, world!')
modified
542acb0cd51b395418700a19da47b2d0abb4daf077056637fae3d87a1565617b
self.assertEqual|test_check_gzip|import logging import socket import sys import unittest import mock try: from urllib.parse import urlencode except: from urllib import urlencode from test import requires_network, onlyPY3 from urllib3 import ( encode_multipart_formdata, HTTPConnectionPool, ) from urllib3.exceptions impo...
b'hello, world!')
386
8
urllib3/urllib3
train
77
73a451d93645a70b45087894d114972f40120658
train
test/with_dummyserver/test_connectionpool.py
train
urllib3/urllib3:test/with_dummyserver/test_connectionpool.py
522
8
self.assertEqual
test_httplib_headers_case_insensitive
import logging import socket import sys import unittest import mock try: from urllib.parse import urlencode except: from urllib import urlencode from test import requires_network, onlyPY3 from urllib3 import ( encode_multipart_formdata, HTTPConnectionPool, ) from urllib3.exceptions import ( Conne...
r.headers.get_all())
added
e4504fbbd8b1a58d810ac5dea273906b17024cfbfae553ec72c39d9901d25e70
self.assertEqual|test_httplib_headers_case_insensitive|import logging import socket import sys import unittest import mock try: from urllib.parse import urlencode except: from urllib import urlencode from test import requires_network, onlyPY3 from urllib3 import ( encode_multipart_formdata, HTTPConnectionPool, ) from u...
null
null
null
urllib3/urllib3
train
78
5c25a73dfb48e4260c44e19e3a50fb5d46832c52
train
test/with_dummyserver/test_https.py
train
urllib3/urllib3:test/with_dummyserver/test_https.py
38
8
self.assertEqual
test_simple
import logging import ssl import sys import unittest import mock from nose.plugins.skip import SkipTest from dummyserver.testcase import HTTPSDummyServerTestCase from dummyserver.server import DEFAULT_CA, DEFAULT_CA_BAD, DEFAULT_CERTS from test import requires_network from urllib3 import HTTPSConnectionPool import ...
r.data)
modified
fcd55e4c69a8baa34438bb7bb13b20f62996d8e78aaac42ffc71bcf4ed341f67
self.assertEqual|test_simple|import logging import ssl import sys import unittest import mock from nose.plugins.skip import SkipTest from dummyserver.testcase import HTTPSDummyServerTestCase from dummyserver.server import DEFAULT_CA, DEFAULT_CA_BAD, DEFAULT_CERTS from test import requires_network from urllib3 import HT...
r.data)
35
8
urllib3/urllib3
train
78
5c25a73dfb48e4260c44e19e3a50fb5d46832c52
train
test/with_dummyserver/test_https.py
train
urllib3/urllib3:test/with_dummyserver/test_https.py
83
12
self.assertRaises
test_no_ssl
import logging import ssl import sys import unittest import mock from nose.plugins.skip import SkipTest from dummyserver.testcase import HTTPSDummyServerTestCase from dummyserver.server import DEFAULT_CA, DEFAULT_CA_BAD, DEFAULT_CERTS from test import requires_network from urllib3 import HTTPSConnectionPool import ...
SSLError)
modified
d319838e7e8ebc7f30660b8e893c1aa5946abc9f62a866a12ea3b15d6e2185bf
self.assertRaises|test_no_ssl|import logging import ssl import sys import unittest import mock from nose.plugins.skip import SkipTest from dummyserver.testcase import HTTPSDummyServerTestCase from dummyserver.server import DEFAULT_CA, DEFAULT_CA_BAD, DEFAULT_CERTS from test import requires_network from urllib3 import H...
SSLError)
80
12
urllib3/urllib3
train
78
5c25a73dfb48e4260c44e19e3a50fb5d46832c52
train
test/with_dummyserver/test_https.py
train
urllib3/urllib3:test/with_dummyserver/test_https.py
112
8
self.assertRaises
test_cert_reqs_as_short_string
import logging import ssl import sys import unittest import mock from nose.plugins.skip import SkipTest from dummyserver.testcase import HTTPSDummyServerTestCase from dummyserver.server import DEFAULT_CA, DEFAULT_CA_BAD, DEFAULT_CERTS from test import requires_network from urllib3 import HTTPSConnectionPool import ...
SSLError)
modified
aa65617e58b3d113fe5c9f4a84ff60ad16de7f379e2dd5b9fb3bd2b628d43f0d
self.assertRaises|test_cert_reqs_as_short_string|import logging import ssl import sys import unittest import mock from nose.plugins.skip import SkipTest from dummyserver.testcase import HTTPSDummyServerTestCase from dummyserver.server import DEFAULT_CA, DEFAULT_CA_BAD, DEFAULT_CERTS from test import requires_network fr...
SSLError)
109
8
urllib3/urllib3
train
78
5c25a73dfb48e4260c44e19e3a50fb5d46832c52
train
test/with_dummyserver/test_https.py
train
urllib3/urllib3:test/with_dummyserver/test_https.py
293
8
self.assertRaises
test_enhanced_timeout
import logging import ssl import sys import unittest import mock from nose.plugins.skip import SkipTest from dummyserver.testcase import HTTPSDummyServerTestCase from dummyserver.server import DEFAULT_CA, DEFAULT_CA_BAD, DEFAULT_CERTS from test import requires_network from urllib3 import HTTPSConnectionPool import ...
ConnectTimeoutError)
added
e8650d8e3a90f4740172ee2c611deabad59b29a6ad63ff7b1418fd9b92ef1d7a
self.assertRaises|test_enhanced_timeout|import logging import ssl import sys import unittest import mock from nose.plugins.skip import SkipTest from dummyserver.testcase import HTTPSDummyServerTestCase from dummyserver.server import DEFAULT_CA, DEFAULT_CA_BAD, DEFAULT_CERTS from test import requires_network from urllib...
null
null
null
urllib3/urllib3
train
79
5e6f46b1d57fb673b8027fcf4ba2e7be1f1f8fad
train
test/test_collections.py
train
urllib3/urllib3:test/test_collections.py
144
8
self.assertTrue
test_copy
import unittest from urllib3._collections import ( HTTPHeaderDict, RecentlyUsedContainer as Container ) from urllib3.packages import six xrange = six.moves.xrange class TestLRUContainer(unittest.TestCase): def test_maxsize(self): d = Container(5) for i in xrange(5): d[i] = st...
self.d is not h)
modified
c2511d62b5940ebcde88cea7e2ab6cc101be44fb1d28c336d66bfd148ac4ebdb
self.assertTrue|test_copy|import unittest from urllib3._collections import ( HTTPHeaderDict, RecentlyUsedContainer as Container ) from urllib3.packages import six xrange = six.moves.xrange class TestLRUContainer(unittest.TestCase): def test_maxsize(self): d = Container(5) for i in xrange(5): d[i] = str(i) self.assertEq...
self.d is not h)
144
8
urllib3/urllib3
train
79
5e6f46b1d57fb673b8027fcf4ba2e7be1f1f8fad
train
test/test_collections.py
train
urllib3/urllib3:test/test_collections.py
153
8
self.assertEqual
test_add
import unittest from urllib3._collections import ( HTTPHeaderDict, RecentlyUsedContainer as Container ) from urllib3.packages import six xrange = six.moves.xrange class TestLRUContainer(unittest.TestCase): def test_maxsize(self): d = Container(5) for i in xrange(5): d[i] = st...
'foo, bar')
added
1fff5d863a42f878cda4ccac5b59fc60b6abb59a3947ed23a5e99c032b1938a9
self.assertEqual|test_add|import unittest from urllib3._collections import ( HTTPHeaderDict, RecentlyUsedContainer as Container ) from urllib3.packages import six xrange = six.moves.xrange class TestLRUContainer(unittest.TestCase): def test_maxsize(self): d = Container(5) for i in xrange(5): d[i] = str(i) self.assertEq...
null
null
null
urllib3/urllib3
train
79
5e6f46b1d57fb673b8027fcf4ba2e7be1f1f8fad
train
test/test_collections.py
train
urllib3/urllib3:test/test_collections.py
157
8
self.assertEqual
test_getlist
import unittest from urllib3._collections import ( HTTPHeaderDict, RecentlyUsedContainer as Container ) from urllib3.packages import six xrange = six.moves.xrange class TestLRUContainer(unittest.TestCase): def test_maxsize(self): d = Container(5) for i in xrange(5): d[i] = st...
['foo', 'bar'])
added
968518c111b54e57b1d02ca83640fca80ae075581f9dda25121b8cc57ab9f136
self.assertEqual|test_getlist|import unittest from urllib3._collections import ( HTTPHeaderDict, RecentlyUsedContainer as Container ) from urllib3.packages import six xrange = six.moves.xrange class TestLRUContainer(unittest.TestCase): def test_maxsize(self): d = Container(5) for i in xrange(5): d[i] = str(i) self.asse...
null
null
null
urllib3/urllib3
train
79
5e6f46b1d57fb673b8027fcf4ba2e7be1f1f8fad
train
test/test_collections.py
train
urllib3/urllib3:test/test_collections.py
163
8
self.assertFalse
test_delitem
import unittest from urllib3._collections import ( HTTPHeaderDict, RecentlyUsedContainer as Container ) from urllib3.packages import six xrange = six.moves.xrange class TestLRUContainer(unittest.TestCase): def test_maxsize(self): d = Container(5) for i in xrange(5): d[i] = st...
'a' in self.d)
added
19564efcde7c8e70f7774cfa0ab5d573b3413e24db0334df010f9a065966e26b
self.assertFalse|test_delitem|import unittest from urllib3._collections import ( HTTPHeaderDict, RecentlyUsedContainer as Container ) from urllib3.packages import six xrange = six.moves.xrange class TestLRUContainer(unittest.TestCase): def test_maxsize(self): d = Container(5) for i in xrange(5): d[i] = str(i) self.asse...
null
null
null
urllib3/urllib3
train
80
ce59082c8fc42831c446dcebb2f6a6178136e136
train
test/with_dummyserver/test_https.py
train
urllib3/urllib3:test/with_dummyserver/test_https.py
160
8
self.assertRaises
test_invalid_ca_certs
import logging import ssl import sys import unittest import mock from nose.plugins.skip import SkipTest from dummyserver.testcase import HTTPSDummyServerTestCase from dummyserver.server import DEFAULT_CA, DEFAULT_CA_BAD, DEFAULT_CERTS from test import requires_network from urllib3 import HTTPSConnectionPool import ...
SSLError)
modified
866ad6889a1bda81642bda124309ce3d5ef1993c2d03bcbcd0f941610d7227f9
self.assertRaises|test_invalid_ca_certs|import logging import ssl import sys import unittest import mock from nose.plugins.skip import SkipTest from dummyserver.testcase import HTTPSDummyServerTestCase from dummyserver.server import DEFAULT_CA, DEFAULT_CA_BAD, DEFAULT_CERTS from test import requires_network from urllib...
SSLError)
160
8
urllib3/urllib3
train
80
ce59082c8fc42831c446dcebb2f6a6178136e136
train
test/with_dummyserver/test_https.py
train
urllib3/urllib3:test/with_dummyserver/test_https.py
204
8
self.assertRaises
test_assert_invalid_fingerprint
import logging import ssl import sys import unittest import mock from nose.plugins.skip import SkipTest from dummyserver.testcase import HTTPSDummyServerTestCase from dummyserver.server import DEFAULT_CA, DEFAULT_CA_BAD, DEFAULT_CERTS from test import requires_network from urllib3 import HTTPSConnectionPool import ...
SSLError)
modified
1968e658a9a61d83e31c40337865089f2eda2d81b8cc7f0cf7ac6a20b0ff6f2e
self.assertRaises|test_assert_invalid_fingerprint|import logging import ssl import sys import unittest import mock from nose.plugins.skip import SkipTest from dummyserver.testcase import HTTPSDummyServerTestCase from dummyserver.server import DEFAULT_CA, DEFAULT_CA_BAD, DEFAULT_CERTS from test import requires_network f...
SSLError)
204
8
urllib3/urllib3
train
80
ce59082c8fc42831c446dcebb2f6a6178136e136
train
test/with_dummyserver/test_https.py
train
urllib3/urllib3:test/with_dummyserver/test_https.py
237
8
self.assertRaises
test_https_timeout
import logging import ssl import sys import unittest import mock from nose.plugins.skip import SkipTest from dummyserver.testcase import HTTPSDummyServerTestCase from dummyserver.server import DEFAULT_CA, DEFAULT_CA_BAD, DEFAULT_CERTS from test import requires_network from urllib3 import HTTPSConnectionPool import ...
ReadTimeoutError)
modified
89f89587e77dff7f6dca2c0333e0475983a0198eb82f018c6cd14b02c8985e32
self.assertRaises|test_https_timeout|import logging import ssl import sys import unittest import mock from nose.plugins.skip import SkipTest from dummyserver.testcase import HTTPSDummyServerTestCase from dummyserver.server import DEFAULT_CA, DEFAULT_CA_BAD, DEFAULT_CERTS from test import requires_network from urllib3 i...
ReadTimeoutError)
237
8
urllib3/urllib3
train
80
ce59082c8fc42831c446dcebb2f6a6178136e136
train
test/with_dummyserver/test_https.py
train
urllib3/urllib3:test/with_dummyserver/test_https.py
324
8
self.assertRaises
test_ssl_version_as_short_string
import logging import ssl import sys import unittest import mock from nose.plugins.skip import SkipTest from dummyserver.testcase import HTTPSDummyServerTestCase from dummyserver.server import DEFAULT_CA, DEFAULT_CA_BAD, DEFAULT_CERTS from test import requires_network from urllib3 import HTTPSConnectionPool import ...
SSLError)
modified
1e027f3f37cf8cf0fb294302bd34735ca51bf5c0ad78c1371bf44e773db8a878
self.assertRaises|test_ssl_version_as_short_string|import logging import ssl import sys import unittest import mock from nose.plugins.skip import SkipTest from dummyserver.testcase import HTTPSDummyServerTestCase from dummyserver.server import DEFAULT_CA, DEFAULT_CA_BAD, DEFAULT_CERTS from test import requires_network ...
SSLError)
324
8
urllib3/urllib3
train
81
887ed4f05a30be73520899e037c6a846579afe07
train
test/with_dummyserver/test_connectionpool.py
train
urllib3/urllib3:test/with_dummyserver/test_connectionpool.py
522
8
self.assertEqual
test_httplib_headers_case_insensitive
import logging import socket import sys import unittest import mock try: from urllib.parse import urlencode except: from urllib import urlencode from test import requires_network, onlyPY3 from urllib3 import ( encode_multipart_formdata, HTTPConnectionPool, ) from urllib3.exceptions import ( Conne...
dict(r.headers.items()))
modified
fe472d761b3d44782103e7aedc1194268c5434159bd488e3183469ceb1e759ea
self.assertEqual|test_httplib_headers_case_insensitive|import logging import socket import sys import unittest import mock try: from urllib.parse import urlencode except: from urllib import urlencode from test import requires_network, onlyPY3 from urllib3 import ( encode_multipart_formdata, HTTPConnectionPool, ) from u...
r.headers.get_all())
522
8
urllib3/urllib3
train
82
59710c2d77ccdf8e234e7a7717e727f0310963e1
train
test/test_filepost.py
val
urllib3/urllib3:test/test_filepost.py
127
6
self.assertEqual
test_request_fields
import unittest from urllib3.filepost import encode_multipart_formdata, iter_fields from urllib3.fields import RequestField from urllib3.packages.six import b, u BOUNDARY = '!! test boundary !!' class TestIterfields(unittest.TestCase): def test_dict(self): for fieldname, value in iter_fields(dict(a='b...
b'--' + b(BOUNDARY) + b'\r\n' b'Content-Type: image/jpeg\r\n' b'\r\n' b'v\r\n' b'--' + b(BOUNDARY) + b'--\r\n')
added
246508bc6541691e28b1b9804b6fb62a38c21854c4cb2d3a58a7f4949d5e5115
self.assertEqual|test_request_fields|import unittest from urllib3.filepost import encode_multipart_formdata, iter_fields from urllib3.fields import RequestField from urllib3.packages.six import b, u BOUNDARY = '!! test boundary !!' class TestIterfields(unittest.TestCase): def test_dict(self): for fieldname, value in it...
null
null
null
urllib3/urllib3
train
82
59710c2d77ccdf8e234e7a7717e727f0310963e1
train
test/test_util.py
train
urllib3/urllib3:test/test_util.py
67
12
self.assertEqual
test_get_host
import logging import unittest from mock import patch from urllib3 import add_stderr_logger from urllib3.util import ( get_host, make_headers, split_first, parse_url, Timeout, Url, ) from urllib3.exceptions import LocationParseError, TimeoutStateError # This number represents a time in second...
expected_host)
added
1e30118d6b5e093a3ca77e60b63879d9898e992deca40c32df719f40636da7dd
self.assertEqual|test_get_host|import logging import unittest from mock import patch from urllib3 import add_stderr_logger from urllib3.util import ( get_host, make_headers, split_first, parse_url, Timeout, Url, ) from urllib3.exceptions import LocationParseError, TimeoutStateError # This number represents a time in se...
null
null
null
urllib3/urllib3
train
82
59710c2d77ccdf8e234e7a7717e727f0310963e1
train
test/test_util.py
train
urllib3/urllib3:test/test_util.py
116
8
self.assertRaises
test_parse_url_invalid_IPv6
import logging import unittest from mock import patch from urllib3 import add_stderr_logger from urllib3.util import ( get_host, make_headers, split_first, parse_url, Timeout, Url, ) from urllib3.exceptions import LocationParseError, TimeoutStateError # This number represents a time in second...
ValueError)
modified
a1839910425c28c0a4f0d583eb7080e585ec362f1765347874ef27086579cc92
self.assertRaises|test_parse_url_invalid_IPv6|import logging import unittest from mock import patch from urllib3 import add_stderr_logger from urllib3.util import ( get_host, make_headers, split_first, parse_url, Timeout, Url, ) from urllib3.exceptions import LocationParseError, TimeoutStateError # This number represen...
ValueError)
116
8
urllib3/urllib3
train
82
59710c2d77ccdf8e234e7a7717e727f0310963e1
train
test/test_util.py
train
urllib3/urllib3:test/test_util.py
166
8
self.assertEqual
test_make_headers
import logging import unittest from mock import patch from urllib3 import add_stderr_logger from urllib3.util import ( get_host, make_headers, split_first, parse_url, Timeout, Url, ) from urllib3.exceptions import LocationParseError, TimeoutStateError # This number represents a time in second...
{'connection': 'keep-alive'})
modified
013f72b7bb76b4568e57ae154f624a4eaf8a027194713286732f231901816f7d
self.assertEqual|test_make_headers|import logging import unittest from mock import patch from urllib3 import add_stderr_logger from urllib3.util import ( get_host, make_headers, split_first, parse_url, Timeout, Url, ) from urllib3.exceptions import LocationParseError, TimeoutStateError # This number represents a time i...
{'connection': 'keep-alive'})
166
8
urllib3/urllib3
train
82
59710c2d77ccdf8e234e7a7717e727f0310963e1
train
test/with_dummyserver/test_socketlevel.py
train
urllib3/urllib3:test/with_dummyserver/test_socketlevel.py
68
8
self.assertTrue
test_hostname_in_first_request_packet
from urllib3 import HTTPConnectionPool, HTTPSConnectionPool from urllib3.poolmanager import proxy_from_url from urllib3.exceptions import ( MaxRetryError, ProxyError, ReadTimeoutError, SSLError, ) from urllib3 import util from dummyserver.testcase import SocketDummyServerTestCase from ...
self.host.encode() in self.buf)
modified
2e4f732b32a6fe080cd0052e44a96044cbc9fa2e8a05cfa7ad065b89427e6091
self.assertTrue|test_hostname_in_first_request_packet|from urllib3 import HTTPConnectionPool, HTTPSConnectionPool from urllib3.poolmanager import proxy_from_url from urllib3.exceptions import ( MaxRetryError, ProxyError, ReadTimeoutError, SSLError, ) from urllib3 import util from dummyserver.testcase import SocketDummy...
self.host.encode() in self.buf)
68
8
urllib3/urllib3
train
82
59710c2d77ccdf8e234e7a7717e727f0310963e1
train
test/with_dummyserver/test_socketlevel.py
train
urllib3/urllib3:test/with_dummyserver/test_socketlevel.py
116
8
self.assertRaises
test_connection_refused
from urllib3 import HTTPConnectionPool, HTTPSConnectionPool from urllib3.poolmanager import proxy_from_url from urllib3.exceptions import ( MaxRetryError, ProxyError, ReadTimeoutError, SSLError, ) from urllib3 import util from dummyserver.testcase import SocketDummyServerTestCase from ...
MaxRetryError)
modified
857f318c8f70794e35cb3a817ff709124f4e4945d422d8bd66182ea899c6ecbe
self.assertRaises|test_connection_refused|from urllib3 import HTTPConnectionPool, HTTPSConnectionPool from urllib3.poolmanager import proxy_from_url from urllib3.exceptions import ( MaxRetryError, ProxyError, ReadTimeoutError, SSLError, ) from urllib3 import util from dummyserver.testcase import SocketDummyServerTestCa...
MaxRetryError)
116
8
urllib3/urllib3
train
82
59710c2d77ccdf8e234e7a7717e727f0310963e1
train
test/with_dummyserver/test_socketlevel.py
train
urllib3/urllib3:test/with_dummyserver/test_socketlevel.py
204
8
self.assertEqual
test_simple
from urllib3 import HTTPConnectionPool, HTTPSConnectionPool from urllib3.poolmanager import proxy_from_url from urllib3.exceptions import ( MaxRetryError, ProxyError, ReadTimeoutError, SSLError, ) from urllib3 import util from dummyserver.testcase import SocketDummyServerTestCase from ...
sorted([ b'GET http://google.com/ HTTP/1.1', b'Host: google.com', b'Accept-Encoding: identity', b'Accept: */*', b'', b'', ]))
modified
a612cbb1d950f6cee195765fe41fa3beb77c749ef289f35847cc68c31e8ecd21
self.assertEqual|test_simple|from urllib3 import HTTPConnectionPool, HTTPSConnectionPool from urllib3.poolmanager import proxy_from_url from urllib3.exceptions import ( MaxRetryError, ProxyError, ReadTimeoutError, SSLError, ) from urllib3 import util from dummyserver.testcase import SocketDummyServerTestCase from dummy...
sorted([ b'GET http://google.com/ HTTP/1.1', b'Host: google.com', b'Accept-Encoding: identity', b'Accept: */*', b'', b'', ]))
204
8
urllib3/urllib3
train
82
59710c2d77ccdf8e234e7a7717e727f0310963e1
train
test/with_dummyserver/test_socketlevel.py
train
urllib3/urllib3:test/with_dummyserver/test_socketlevel.py
276
8
self.assertRaises
test_retries
from urllib3 import HTTPConnectionPool, HTTPSConnectionPool from urllib3.poolmanager import proxy_from_url from urllib3.exceptions import ( MaxRetryError, ProxyError, ReadTimeoutError, SSLError, ) from urllib3 import util from dummyserver.testcase import SocketDummyServerTestCase from ...
ProxyError)
modified
f7f4ccff4c14fc40b0729885da569ceb1c7d2fc29b904bc524fdb5b818172bdf
self.assertRaises|test_retries|from urllib3 import HTTPConnectionPool, HTTPSConnectionPool from urllib3.poolmanager import proxy_from_url from urllib3.exceptions import ( MaxRetryError, ProxyError, ReadTimeoutError, SSLError, ) from urllib3 import util from dummyserver.testcase import SocketDummyServerTestCase from dum...
ProxyError)
276
8
urllib3/urllib3
train
83
74d862c3e35a1e88382955621271d4ba7f50cb50
train
test/test_exceptions.py
val
urllib3/urllib3:test/test_exceptions.py
18
8
assert
test_exceptions
import unittest import pickle from urllib3.exceptions import (HTTPError, MaxRetryError, LocationParseError, ClosedPoolError, EmptyPoolError, HostChangedError, ReadTimeoutError, ConnectTimeoutError) from urllib3.connectionpo...
self.verify_pickling(HTTPError(None))
modified
90d958db93f826e1d8888806e55942244a76b93f8b41dbdb70b5762112748c28
assert|test_exceptions|import unittest import pickle from urllib3.exceptions import (HTTPError, MaxRetryError, LocationParseError, ClosedPoolError, EmptyPoolError, HostChangedError, ReadTimeoutError, ConnectTimeoutError) from urllib3.connectionpool import HTTPConnectionPool class TestPickle(unittest.TestCase): def veri...
self.cycle(HTTPError(None))
18
8
urllib3/urllib3
train
83
74d862c3e35a1e88382955621271d4ba7f50cb50
train
test/test_exceptions.py
val
urllib3/urllib3:test/test_exceptions.py
20
8
assert
test_exceptions
import unittest import pickle from urllib3.exceptions import (HTTPError, MaxRetryError, LocationParseError, ClosedPoolError, EmptyPoolError, HostChangedError, ReadTimeoutError, ConnectTimeoutError) from urllib3.connectionpo...
self.verify_pickling(LocationParseError(None))
modified
1be450ae24e1313832219e5248a3fc083cb5321f30dc6f49c8b9d54b05deeb19
assert|test_exceptions|import unittest import pickle from urllib3.exceptions import (HTTPError, MaxRetryError, LocationParseError, ClosedPoolError, EmptyPoolError, HostChangedError, ReadTimeoutError, ConnectTimeoutError) from urllib3.connectionpool import HTTPConnectionPool class TestPickle(unittest.TestCase): def veri...
self.cycle(LocationParseError(None))
20
8
urllib3/urllib3
train
83
74d862c3e35a1e88382955621271d4ba7f50cb50
train
test/test_exceptions.py
val
urllib3/urllib3:test/test_exceptions.py
24
8
assert
test_exceptions_with_objects
import unittest import pickle from urllib3.exceptions import (HTTPError, MaxRetryError, LocationParseError, ClosedPoolError, EmptyPoolError, HostChangedError, ReadTimeoutError, ConnectTimeoutError) from urllib3.connectionpo...
self.verify_pickling( HTTPError('foo'))
modified
c1fe79641af0299a955a367b9c9fafff16d093e5be876012fbff04f4347951dd
assert|test_exceptions_with_objects|import unittest import pickle from urllib3.exceptions import (HTTPError, MaxRetryError, LocationParseError, ClosedPoolError, EmptyPoolError, HostChangedError, ReadTimeoutError, ConnectTimeoutError) from urllib3.connectionpool import HTTPConnectionPool class TestPickle(unittest.TestCa...
self.cycle(HTTPError('foo'))
24
8
urllib3/urllib3
train
83
74d862c3e35a1e88382955621271d4ba7f50cb50
train
test/test_exceptions.py
val
urllib3/urllib3:test/test_exceptions.py
27
8
assert
test_exceptions_with_objects
import unittest import pickle from urllib3.exceptions import (HTTPError, MaxRetryError, LocationParseError, ClosedPoolError, EmptyPoolError, HostChangedError, ReadTimeoutError, ConnectTimeoutError) from urllib3.connectionpo...
self.verify_pickling( HTTPError('foo', IOError('foo')))
added
cdff20341fc74d32304e84992415f74b9d022143a38c4702dace6cb3c087dea8
assert|test_exceptions_with_objects|import unittest import pickle from urllib3.exceptions import (HTTPError, MaxRetryError, LocationParseError, ClosedPoolError, EmptyPoolError, HostChangedError, ReadTimeoutError, ConnectTimeoutError) from urllib3.connectionpool import HTTPConnectionPool class TestPickle(unittest.TestCa...
null
null
null
urllib3/urllib3
train
83
74d862c3e35a1e88382955621271d4ba7f50cb50
train
test/with_dummyserver/test_connectionpool.py
train
urllib3/urllib3:test/with_dummyserver/test_connectionpool.py
60
8
self.assertEqual
test_urlopen_put
import logging import socket import sys import unittest import mock try: from urllib.parse import urlencode except: from urllib import urlencode from test import requires_network, onlyPY3 from urllib3 import ( encode_multipart_formdata, HTTPConnectionPool, ) from urllib3.exceptions import ( Conne...
r.data)
modified
9fb9457d5c553b73764ecd2bfae363ea2eb8a52d55a0d592f2c3a6545cfc6a04
self.assertEqual|test_urlopen_put|import logging import socket import sys import unittest import mock try: from urllib.parse import urlencode except: from urllib import urlencode from test import requires_network, onlyPY3 from urllib3 import ( encode_multipart_formdata, HTTPConnectionPool, ) from urllib3.exceptions imp...
r.data)
59
8
urllib3/urllib3
train
83
74d862c3e35a1e88382955621271d4ba7f50cb50
train
test/with_dummyserver/test_connectionpool.py
train
urllib3/urllib3:test/with_dummyserver/test_connectionpool.py
82
8
self.assertEqual
test_upload
import logging import socket import sys import unittest import mock try: from urllib.parse import urlencode except: from urllib import urlencode from test import requires_network, onlyPY3 from urllib3 import ( encode_multipart_formdata, HTTPConnectionPool, ) from urllib3.exceptions import ( Conne...
r.data)
modified
39e853f231441b23cf73b3829a7000d48cc28dc78ac9a0fcfb11c742295254f2
self.assertEqual|test_upload|import logging import socket import sys import unittest import mock try: from urllib.parse import urlencode except: from urllib import urlencode from test import requires_network, onlyPY3 from urllib3 import ( encode_multipart_formdata, HTTPConnectionPool, ) from urllib3.exceptions import (...
r.data)
81
8
urllib3/urllib3
train
83
74d862c3e35a1e88382955621271d4ba7f50cb50
train
test/with_dummyserver/test_connectionpool.py
train
urllib3/urllib3:test/with_dummyserver/test_connectionpool.py
421
8
self.assertRaises
test_bad_decode
import logging import socket import sys import unittest import mock try: from urllib.parse import urlencode except: from urllib import urlencode from test import requires_network, onlyPY3 from urllib3 import ( encode_multipart_formdata, HTTPConnectionPool, ) from urllib3.exceptions import ( Conne...
DecodeError)
added
ac8bf7f1a6f2a02ba441d17695d21440fed3e2cb0d321a697aa70ad993cd40a1
self.assertRaises|test_bad_decode|import logging import socket import sys import unittest import mock try: from urllib.parse import urlencode except: from urllib import urlencode from test import requires_network, onlyPY3 from urllib3 import ( encode_multipart_formdata, HTTPConnectionPool, ) from urllib3.exceptions imp...
null
null
null
urllib3/urllib3
train
83
74d862c3e35a1e88382955621271d4ba7f50cb50
train
test/with_dummyserver/test_connectionpool.py
train
urllib3/urllib3:test/with_dummyserver/test_connectionpool.py
545
8
self.assertEqual
test_httplib_headers_case_insensitive
import logging import socket import sys import unittest import mock try: from urllib.parse import urlencode except: from urllib import urlencode from test import requires_network, onlyPY3 from urllib3 import ( encode_multipart_formdata, HTTPConnectionPool, ) from urllib3.exceptions import ( Conne...
dict(r.headers.items()))
added
143b18a6ba518a292e9f60dc4b390c0d54d4f132d50bc794f95fbdbacd2811c1
self.assertEqual|test_httplib_headers_case_insensitive|import logging import socket import sys import unittest import mock try: from urllib.parse import urlencode except: from urllib import urlencode from test import requires_network, onlyPY3 from urllib3 import ( encode_multipart_formdata, HTTPConnectionPool, ) from u...
null
null
null
urllib3/urllib3
train
84
04cb87bdbeff8ae5685bc3a5fd2afc70fb811aab
train
test/test_util.py
train
urllib3/urllib3:test/test_util.py
248
8
self.assertEqual
test_timeout
import logging import unittest from mock import patch from urllib3 import add_stderr_logger from urllib3.util import ( get_host, make_headers, split_first, parse_url, Timeout, Url, ) from urllib3.exceptions import LocationParseError, TimeoutStateError # This number represents a time in second...
Timeout.DEFAULT_TIMEOUT)
modified
b6266b719a79f23cbd584330d5f05c4ecba44c30256ce742fdda90c56715e7fe
self.assertEqual|test_timeout|import logging import unittest from mock import patch from urllib3 import add_stderr_logger from urllib3.util import ( get_host, make_headers, split_first, parse_url, Timeout, Url, ) from urllib3.exceptions import LocationParseError, TimeoutStateError # This number represents a time in sec...
Timeout.DEFAULT_TIMEOUT)
248
8
urllib3/urllib3
train
84
04cb87bdbeff8ae5685bc3a5fd2afc70fb811aab
train
test/test_util.py
train
urllib3/urllib3:test/test_util.py
276
8
self.assertEqual
test_timeout_str
import logging import unittest from mock import patch from urllib3 import add_stderr_logger from urllib3.util import ( get_host, make_headers, split_first, parse_url, Timeout, Url, ) from urllib3.exceptions import LocationParseError, TimeoutStateError # This number represents a time in second...
"Timeout(connect=1, read=2, total=3)")
modified
9db159bcfa9ef8fe0ef02301c3b0c06e41a3619365e5c6ca5156bb96a65ad28e
self.assertEqual|test_timeout_str|import logging import unittest from mock import patch from urllib3 import add_stderr_logger from urllib3.util import ( get_host, make_headers, split_first, parse_url, Timeout, Url, ) from urllib3.exceptions import LocationParseError, TimeoutStateError # This number represents a time in...
"Timeout(connect=1, read=2, total=3)")
276
8
urllib3/urllib3
train
84
04cb87bdbeff8ae5685bc3a5fd2afc70fb811aab
train
test/test_util.py
train
urllib3/urllib3:test/test_util.py
278
8
self.assertEqual
test_timeout_str
import logging import unittest from mock import patch from urllib3 import add_stderr_logger from urllib3.util import ( get_host, make_headers, split_first, parse_url, Timeout, Url, ) from urllib3.exceptions import LocationParseError, TimeoutStateError # This number represents a time in second...
"Timeout(connect=1, read=None, total=3)")
modified
4b6e00b0511c40611d662e72eeedeb870cff9c3c5a45c4b4665fb1085af18999
self.assertEqual|test_timeout_str|import logging import unittest from mock import patch from urllib3 import add_stderr_logger from urllib3.util import ( get_host, make_headers, split_first, parse_url, Timeout, Url, ) from urllib3.exceptions import LocationParseError, TimeoutStateError # This number represents a time in...
"Timeout(connect=1, read=None, total=3)")
278
8
urllib3/urllib3
train
84
04cb87bdbeff8ae5685bc3a5fd2afc70fb811aab
train
test/test_util.py
train
urllib3/urllib3:test/test_util.py
288
8
self.assertRaises
test_timeout_elapsed
import logging import unittest from mock import patch from urllib3 import add_stderr_logger from urllib3.util import ( get_host, make_headers, split_first, parse_url, Timeout, Url, ) from urllib3.exceptions import LocationParseError, TimeoutStateError # This number represents a time in second...
TimeoutStateError)
modified
804d0931005d467637ad3fbf3b40b230bc809ef60ffe167d3b06bf89190632c6
self.assertRaises|test_timeout_elapsed|import logging import unittest from mock import patch from urllib3 import add_stderr_logger from urllib3.util import ( get_host, make_headers, split_first, parse_url, Timeout, Url, ) from urllib3.exceptions import LocationParseError, TimeoutStateError # This number represents a ti...
TimeoutStateError)
288
8
urllib3/urllib3
train
85
b088e93a48fb96138ddea7366e679a77762e2f00
train
test/test_poolmanager.py
train
urllib3/urllib3:test/test_poolmanager.py
60
8
self.assertRaises
test_manager_clear
import unittest from urllib3.poolmanager import PoolManager from urllib3 import connection_from_url from urllib3.exceptions import ( ClosedPoolError, LocationParseError, ) class TestPoolManager(unittest.TestCase): def test_same_url(self): # Convince ourselves that normally we don't get the same o...
ClosedPoolError)
modified
66fe229a3e306987b2a7e857bf612c04067a85e65053a771891f4f2320c7966f
self.assertRaises|test_manager_clear|import unittest from urllib3.poolmanager import PoolManager from urllib3 import connection_from_url from urllib3.exceptions import ( ClosedPoolError, LocationParseError, ) class TestPoolManager(unittest.TestCase): def test_same_url(self): # Convince ourselves that normally we don't ...
ClosedPoolError)
57
8
urllib3/urllib3
train
85
b088e93a48fb96138ddea7366e679a77762e2f00
train
test/test_poolmanager.py
train
urllib3/urllib3:test/test_poolmanager.py
64
8
self.assertRaises
test_manager_clear
import unittest from urllib3.poolmanager import PoolManager from urllib3 import connection_from_url from urllib3.exceptions import ( ClosedPoolError, LocationParseError, ) class TestPoolManager(unittest.TestCase): def test_same_url(self): # Convince ourselves that normally we don't get the same o...
ClosedPoolError)
modified
1143da63ba14d209a4c8754b1b1531bb1e670f9428b2aa147cc5ec23258b1008
self.assertRaises|test_manager_clear|import unittest from urllib3.poolmanager import PoolManager from urllib3 import connection_from_url from urllib3.exceptions import ( ClosedPoolError, LocationParseError, ) class TestPoolManager(unittest.TestCase): def test_same_url(self): # Convince ourselves that normally we don't ...
ClosedPoolError)
61
8
urllib3/urllib3
train
85
b088e93a48fb96138ddea7366e679a77762e2f00
train
test/test_poolmanager.py
train
urllib3/urllib3:test/test_poolmanager.py
71
8
self.assertRaises
test_nohost
import unittest from urllib3.poolmanager import PoolManager from urllib3 import connection_from_url from urllib3.exceptions import ( ClosedPoolError, LocationParseError, ) class TestPoolManager(unittest.TestCase): def test_same_url(self): # Convince ourselves that normally we don't get the same o...
LocationParseError)
added
6f609c71e7b52e02821d50df7bc93b4351bc847675bc0dd934c79ce86abd122d
self.assertRaises|test_nohost|import unittest from urllib3.poolmanager import PoolManager from urllib3 import connection_from_url from urllib3.exceptions import ( ClosedPoolError, LocationParseError, ) class TestPoolManager(unittest.TestCase): def test_same_url(self): # Convince ourselves that normally we don't get the...
null
null
null
urllib3/urllib3
train
85
b088e93a48fb96138ddea7366e679a77762e2f00
train
test/test_util.py
train
urllib3/urllib3:test/test_util.py
115
12
self.assertEqual
test_parse_url
import logging import unittest from mock import patch from urllib3 import add_stderr_logger from urllib3.util import ( get_host, make_headers, split_first, parse_url, Timeout, Url, ) from urllib3.exceptions import LocationParseError, TimeoutStateError # This number represents a time in second...
expected_url)
modified
b62467ca540551a78326153a2a617a0c2a6485740c559a44b07e6f35067a760a
self.assertEqual|test_parse_url|import logging import unittest from mock import patch from urllib3 import add_stderr_logger from urllib3.util import ( get_host, make_headers, split_first, parse_url, Timeout, Url, ) from urllib3.exceptions import LocationParseError, TimeoutStateError # This number represents a time in s...
expected_url)
113
12
urllib3/urllib3
train
85
b088e93a48fb96138ddea7366e679a77762e2f00
train
test/test_util.py
train
urllib3/urllib3:test/test_util.py
118
8
self.assertRaises
test_parse_url_invalid_IPv6
import logging import unittest from mock import patch from urllib3 import add_stderr_logger from urllib3.util import ( get_host, make_headers, split_first, parse_url, Timeout, Url, ) from urllib3.exceptions import LocationParseError, TimeoutStateError # This number represents a time in second...
ValueError)
modified
bbf74f35b2b954cf46cf7c6777081af79a1dcddcfe39793b6c56abf926d6bcc0
self.assertRaises|test_parse_url_invalid_IPv6|import logging import unittest from mock import patch from urllib3 import add_stderr_logger from urllib3.util import ( get_host, make_headers, split_first, parse_url, Timeout, Url, ) from urllib3.exceptions import LocationParseError, TimeoutStateError # This number represen...
ValueError)
116
8
urllib3/urllib3
train
85
b088e93a48fb96138ddea7366e679a77762e2f00
train
test/test_util.py
train
urllib3/urllib3:test/test_util.py
190
12
self.assertEqual
test_split_first
import logging import unittest from mock import patch from urllib3 import add_stderr_logger from urllib3.util import ( get_host, make_headers, split_first, parse_url, Timeout, Url, ) from urllib3.exceptions import LocationParseError, TimeoutStateError # This number represents a time in second...
expected)
modified
26a5b070cf28691f81f027fdf1b6569b5c9ddcb86779ca7b351f3d5ee65e085d
self.assertEqual|test_split_first|import logging import unittest from mock import patch from urllib3 import add_stderr_logger from urllib3.util import ( get_host, make_headers, split_first, parse_url, Timeout, Url, ) from urllib3.exceptions import LocationParseError, TimeoutStateError # This number represents a time in...
expected)
188
12
urllib3/urllib3
train
85
b088e93a48fb96138ddea7366e679a77762e2f00
train
test/test_util.py
train
urllib3/urllib3:test/test_util.py
195
8
self.assertTrue
test_add_stderr_logger
import logging import unittest from mock import patch from urllib3 import add_stderr_logger from urllib3.util import ( get_host, make_headers, split_first, parse_url, Timeout, Url, ) from urllib3.exceptions import LocationParseError, TimeoutStateError # This number represents a time in second...
handler in logger.handlers)
modified
a249ba64490dbe4a94c5e24df73086f817c186de5abd4006d1d24b889b8ce725
self.assertTrue|test_add_stderr_logger|import logging import unittest from mock import patch from urllib3 import add_stderr_logger from urllib3.util import ( get_host, make_headers, split_first, parse_url, Timeout, Url, ) from urllib3.exceptions import LocationParseError, TimeoutStateError # This number represents a ti...
handler in logger.handlers)
193
8
urllib3/urllib3
train
86
5113b528868477fa800829b3b5485b8c66fecd6a
train
test/with_dummyserver/test_https.py
train
urllib3/urllib3:test/with_dummyserver/test_https.py
161
8
self.assertRaises
test_invalid_ca_certs
import logging import ssl import sys import unittest import mock from nose.plugins.skip import SkipTest from dummyserver.testcase import HTTPSDummyServerTestCase from dummyserver.server import DEFAULT_CA, DEFAULT_CA_BAD, DEFAULT_CERTS from test import requires_network from urllib3 import HTTPSConnectionPool import ...
SSLError)
modified
f1e8687a49e684a266a6947a3cc5ada647ff39eb79a5b8dd9bdcbaf4941c83f2
self.assertRaises|test_invalid_ca_certs|import logging import ssl import sys import unittest import mock from nose.plugins.skip import SkipTest from dummyserver.testcase import HTTPSDummyServerTestCase from dummyserver.server import DEFAULT_CA, DEFAULT_CA_BAD, DEFAULT_CERTS from test import requires_network from urllib...
SSLError)
160
8
urllib3/urllib3
train
86
5113b528868477fa800829b3b5485b8c66fecd6a
train
test/with_dummyserver/test_https.py
train
urllib3/urllib3:test/with_dummyserver/test_https.py
205
8
self.assertRaises
test_assert_invalid_fingerprint
import logging import ssl import sys import unittest import mock from nose.plugins.skip import SkipTest from dummyserver.testcase import HTTPSDummyServerTestCase from dummyserver.server import DEFAULT_CA, DEFAULT_CA_BAD, DEFAULT_CERTS from test import requires_network from urllib3 import HTTPSConnectionPool import ...
SSLError)
modified
dfad268440c7a4789664249fe2501e0c4de0b8f4fa769a9f541f4ab34c3f0441
self.assertRaises|test_assert_invalid_fingerprint|import logging import ssl import sys import unittest import mock from nose.plugins.skip import SkipTest from dummyserver.testcase import HTTPSDummyServerTestCase from dummyserver.server import DEFAULT_CA, DEFAULT_CA_BAD, DEFAULT_CERTS from test import requires_network f...
SSLError)
204
8
urllib3/urllib3
train
86
5113b528868477fa800829b3b5485b8c66fecd6a
train
test/with_dummyserver/test_https.py
train
urllib3/urllib3:test/with_dummyserver/test_https.py
238
8
self.assertRaises
test_https_timeout
import logging import ssl import sys import unittest import mock from nose.plugins.skip import SkipTest from dummyserver.testcase import HTTPSDummyServerTestCase from dummyserver.server import DEFAULT_CA, DEFAULT_CA_BAD, DEFAULT_CERTS from test import requires_network from urllib3 import HTTPSConnectionPool import ...
ReadTimeoutError)
modified
15fdb4d7e90a4302e60a0de53e46a9530951152d30cf377c1bb6c2a9a9c82c96
self.assertRaises|test_https_timeout|import logging import ssl import sys import unittest import mock from nose.plugins.skip import SkipTest from dummyserver.testcase import HTTPSDummyServerTestCase from dummyserver.server import DEFAULT_CA, DEFAULT_CA_BAD, DEFAULT_CERTS from test import requires_network from urllib3 i...
ReadTimeoutError)
237
8
urllib3/urllib3
train
86
5113b528868477fa800829b3b5485b8c66fecd6a
train
test/with_dummyserver/test_https.py
train
urllib3/urllib3:test/with_dummyserver/test_https.py
321
8
self.assertRaises
test_ssl_version_as_string
import logging import ssl import sys import unittest import mock from nose.plugins.skip import SkipTest from dummyserver.testcase import HTTPSDummyServerTestCase from dummyserver.server import DEFAULT_CA, DEFAULT_CA_BAD, DEFAULT_CERTS from test import requires_network from urllib3 import HTTPSConnectionPool import ...
SSLError)
modified
eed766cc659034eb05009c85a5403ca889d922ea1f90134869b96f768138245d
self.assertRaises|test_ssl_version_as_string|import logging import ssl import sys import unittest import mock from nose.plugins.skip import SkipTest from dummyserver.testcase import HTTPSDummyServerTestCase from dummyserver.server import DEFAULT_CA, DEFAULT_CA_BAD, DEFAULT_CERTS from test import requires_network from u...
SSLError)
320
8
urllib3/urllib3
train
87
31b223ec2bf83d59a3854529aff786b2a6db018b
train
test/with_dummyserver/test_connectionpool.py
train
urllib3/urllib3:test/with_dummyserver/test_connectionpool.py
49
8
self.assertEqual
test_get
import logging import socket import sys import unittest import mock try: from urllib.parse import urlencode except: from urllib import urlencode from test import ( onlyPy3, onlyPy27OrNewer, onlyPy26OrOlder, requires_network, TARPIT_HOST, VALID_SOURCE_ADDRESSES, INVALID_SOURCE_ADDRESSES) from urllib3 ...
r.data)
added
91ba5f8368f4ef44c3a5d5a483e714ed71923d6d15f3108623e11c0300cffdc1
self.assertEqual|test_get|import logging import socket import sys import unittest import mock try: from urllib.parse import urlencode except: from urllib import urlencode from test import ( onlyPy3, onlyPy27OrNewer, onlyPy26OrOlder, requires_network, TARPIT_HOST, VALID_SOURCE_ADDRESSES, INVALID_SOURCE_ADDRESSES) from u...
null
null
null
urllib3/urllib3
train
87
31b223ec2bf83d59a3854529aff786b2a6db018b
train
test/with_dummyserver/test_connectionpool.py
train
urllib3/urllib3:test/with_dummyserver/test_connectionpool.py
412
8
self.assertEqual
test_check_deflate
import logging import socket import sys import unittest import mock try: from urllib.parse import urlencode except: from urllib import urlencode from test import ( onlyPy3, onlyPy27OrNewer, onlyPy26OrOlder, requires_network, TARPIT_HOST, VALID_SOURCE_ADDRESSES, INVALID_SOURCE_ADDRESSES) from urllib3 ...
b'hello, world!')
modified
4cd0feac329ad0f7a6b0e62908bb3232332d43e74923b3ba14564dbe5871cbc5
self.assertEqual|test_check_deflate|import logging import socket import sys import unittest import mock try: from urllib.parse import urlencode except: from urllib import urlencode from test import ( onlyPy3, onlyPy27OrNewer, onlyPy26OrOlder, requires_network, TARPIT_HOST, VALID_SOURCE_ADDRESSES, INVALID_SOURCE_ADDRESS...
b'hello, world!')
414
8
urllib3/urllib3
train
87
31b223ec2bf83d59a3854529aff786b2a6db018b
train
test/with_dummyserver/test_connectionpool.py
train
urllib3/urllib3:test/with_dummyserver/test_connectionpool.py
415
8
self.assertRaises
test_bad_decode
import logging import socket import sys import unittest import mock try: from urllib.parse import urlencode except: from urllib import urlencode from test import ( onlyPy3, onlyPy27OrNewer, onlyPy26OrOlder, requires_network, TARPIT_HOST, VALID_SOURCE_ADDRESSES, INVALID_SOURCE_ADDRESSES) from urllib3 ...
DecodeError)
modified
5ea6b71476df487577c06c5f81a39176bbd69fd1460d6c06eff763d9dcb4a8ce
self.assertRaises|test_bad_decode|import logging import socket import sys import unittest import mock try: from urllib.parse import urlencode except: from urllib import urlencode from test import ( onlyPy3, onlyPy27OrNewer, onlyPy26OrOlder, requires_network, TARPIT_HOST, VALID_SOURCE_ADDRESSES, INVALID_SOURCE_ADDRESSES...
DecodeError)
417
8
urllib3/urllib3
train
87
31b223ec2bf83d59a3854529aff786b2a6db018b
train
test/with_dummyserver/test_connectionpool.py
train
urllib3/urllib3:test/with_dummyserver/test_connectionpool.py
552
12
assert
test_source_address
import logging import socket import sys import unittest import mock try: from urllib.parse import urlencode except: from urllib import urlencode from test import ( onlyPy3, onlyPy27OrNewer, onlyPy26OrOlder, requires_network, TARPIT_HOST, VALID_SOURCE_ADDRESSES, INVALID_SOURCE_ADDRESSES) from urllib3 ...
b(addr[0])
added
c73a810a6255884892787545edcf43fbde89f2b28e4c1a0b7b9a819ebb05c4b0
assert|test_source_address|import logging import socket import sys import unittest import mock try: from urllib.parse import urlencode except: from urllib import urlencode from test import ( onlyPy3, onlyPy27OrNewer, onlyPy26OrOlder, requires_network, TARPIT_HOST, VALID_SOURCE_ADDRESSES, INVALID_SOURCE_ADDRESSES) from ...
null
null
null
urllib3/urllib3
train
87
31b223ec2bf83d59a3854529aff786b2a6db018b
train
test/with_dummyserver/test_https.py
train
urllib3/urllib3:test/with_dummyserver/test_https.py
82
12
self.assertRaises
test_no_ssl
import logging import ssl import sys import unittest import mock from nose.plugins.skip import SkipTest from dummyserver.testcase import HTTPSDummyServerTestCase from dummyserver.server import DEFAULT_CA, DEFAULT_CA_BAD, DEFAULT_CERTS from test import ( onlyPy3, onlyPy27OrNewer, onlyPy26OrOlder, requires_network...
SSLError)
added
9a575627eb0c9b1b0b4db10d899d43ee09dd50dd8a0b4f19efdd29ddfa3d2c16
self.assertRaises|test_no_ssl|import logging import ssl import sys import unittest import mock from nose.plugins.skip import SkipTest from dummyserver.testcase import HTTPSDummyServerTestCase from dummyserver.server import DEFAULT_CA, DEFAULT_CA_BAD, DEFAULT_CERTS from test import ( onlyPy3, onlyPy27OrNewer, onlyPy26Or...
null
null
null
urllib3/urllib3
train
87
31b223ec2bf83d59a3854529aff786b2a6db018b
train
test/with_dummyserver/test_https.py
train
urllib3/urllib3:test/with_dummyserver/test_https.py
112
8
self.assertRaises
test_cert_reqs_as_short_string
import logging import ssl import sys import unittest import mock from nose.plugins.skip import SkipTest from dummyserver.testcase import HTTPSDummyServerTestCase from dummyserver.server import DEFAULT_CA, DEFAULT_CA_BAD, DEFAULT_CERTS from test import ( onlyPy3, onlyPy27OrNewer, onlyPy26OrOlder, requires_network...
SSLError)
added
42492528ab30a22c49a46b5df46f560de4fbac1c1ab200e212c6bcf8c9b6e385
self.assertRaises|test_cert_reqs_as_short_string|import logging import ssl import sys import unittest import mock from nose.plugins.skip import SkipTest from dummyserver.testcase import HTTPSDummyServerTestCase from dummyserver.server import DEFAULT_CA, DEFAULT_CA_BAD, DEFAULT_CERTS from test import ( onlyPy3, onlyPy27...
null
null
null
urllib3/urllib3
train
87
31b223ec2bf83d59a3854529aff786b2a6db018b
train
test/with_dummyserver/test_https.py
train
urllib3/urllib3:test/with_dummyserver/test_https.py
152
8
self.assertRaises
test_verified_without_ca_certs
import logging import ssl import sys import unittest import mock from nose.plugins.skip import SkipTest from dummyserver.testcase import HTTPSDummyServerTestCase from dummyserver.server import DEFAULT_CA, DEFAULT_CA_BAD, DEFAULT_CERTS from test import ( onlyPy3, onlyPy27OrNewer, onlyPy26OrOlder, requires_network...
SSLError)
added
b87aa2085386f59970a4b019a81ca839c2707a9dec90c7d123c7efbdc0fd6ede
self.assertRaises|test_verified_without_ca_certs|import logging import ssl import sys import unittest import mock from nose.plugins.skip import SkipTest from dummyserver.testcase import HTTPSDummyServerTestCase from dummyserver.server import DEFAULT_CA, DEFAULT_CA_BAD, DEFAULT_CERTS from test import ( onlyPy3, onlyPy27...
null
null
null
urllib3/urllib3
train
87
31b223ec2bf83d59a3854529aff786b2a6db018b
train
test/with_dummyserver/test_https.py
train
urllib3/urllib3:test/with_dummyserver/test_https.py
334
12
self.assertRaises
test_source_address_error
import logging import ssl import sys import unittest import mock from nose.plugins.skip import SkipTest from dummyserver.testcase import HTTPSDummyServerTestCase from dummyserver.server import DEFAULT_CA, DEFAULT_CA_BAD, DEFAULT_CERTS from test import ( onlyPy3, onlyPy27OrNewer, onlyPy26OrOlder, requires_network...
MaxRetryError)
added
ebb7df44732319769a4bcbb406294e8b3211a2f712bd264251c4b4aea09c2ed3
self.assertRaises|test_source_address_error|import logging import ssl import sys import unittest import mock from nose.plugins.skip import SkipTest from dummyserver.testcase import HTTPSDummyServerTestCase from dummyserver.server import DEFAULT_CA, DEFAULT_CA_BAD, DEFAULT_CERTS from test import ( onlyPy3, onlyPy27OrNew...
null
null
null
urllib3/urllib3
train
88
4c70d76bac93c1941bacb7c7a068d4ad8efb2b19
train
test/test_util.py
train
urllib3/urllib3:test/test_util.py
117
12
self.assertEqual
test_parse_url
import logging import unittest import ssl from mock import patch from urllib3 import add_stderr_logger from urllib3.util import ( get_host, make_headers, split_first, parse_url, Timeout, Url, resolve_cert_reqs, ) from urllib3.exceptions import LocationParseError, TimeoutStateError # This ...
expected_url)
modified
66a0f7c3da01e5364f0e37372ec53e68f7a99101397ce4bcdf06ed7412b0d678
self.assertEqual|test_parse_url|import logging import unittest import ssl from mock import patch from urllib3 import add_stderr_logger from urllib3.util import ( get_host, make_headers, split_first, parse_url, Timeout, Url, resolve_cert_reqs, ) from urllib3.exceptions import LocationParseError, TimeoutStateError # This...
expected_url)
115
12
urllib3/urllib3
train
88
4c70d76bac93c1941bacb7c7a068d4ad8efb2b19
train
test/test_util.py
train
urllib3/urllib3:test/test_util.py
136
12
self.assertEqual
test_request_uri
import logging import unittest import ssl from mock import patch from urllib3 import add_stderr_logger from urllib3.util import ( get_host, make_headers, split_first, parse_url, Timeout, Url, resolve_cert_reqs, ) from urllib3.exceptions import LocationParseError, TimeoutStateError # This ...
expected_request_uri)
modified
48c6860b8d47d4d1e74ddf3f0820f08160fa8aaab2da9b2d244143fc850e85dc
self.assertEqual|test_request_uri|import logging import unittest import ssl from mock import patch from urllib3 import add_stderr_logger from urllib3.util import ( get_host, make_headers, split_first, parse_url, Timeout, Url, resolve_cert_reqs, ) from urllib3.exceptions import LocationParseError, TimeoutStateError # Th...
expected_request_uri)
134
12
urllib3/urllib3
train
88
4c70d76bac93c1941bacb7c7a068d4ad8efb2b19
train
test/test_util.py
train
urllib3/urllib3:test/test_util.py
147
12
self.assertEqual
test_netloc
import logging import unittest import ssl from mock import patch from urllib3 import add_stderr_logger from urllib3.util import ( get_host, make_headers, split_first, parse_url, Timeout, Url, resolve_cert_reqs, ) from urllib3.exceptions import LocationParseError, TimeoutStateError # This ...
expected_netloc)
modified
dd72b6e2d9db40b035aba916cbefd82f4da2d7cdb9a782abab29e39785f36f1d
self.assertEqual|test_netloc|import logging import unittest import ssl from mock import patch from urllib3 import add_stderr_logger from urllib3.util import ( get_host, make_headers, split_first, parse_url, Timeout, Url, resolve_cert_reqs, ) from urllib3.exceptions import LocationParseError, TimeoutStateError # This nu...
expected_netloc)
145
12
urllib3/urllib3
train
88
4c70d76bac93c1941bacb7c7a068d4ad8efb2b19
train
test/test_util.py
train
urllib3/urllib3:test/test_util.py
252
8
self.assertEqual
test_timeout
import logging import unittest import ssl from mock import patch from urllib3 import add_stderr_logger from urllib3.util import ( get_host, make_headers, split_first, parse_url, Timeout, Url, resolve_cert_reqs, ) from urllib3.exceptions import LocationParseError, TimeoutStateError # This ...
Timeout.DEFAULT_TIMEOUT)
modified
957de623fea59cfdd28cbab54ac3842404cb9141f5465437cd82aa120a2a31e3
self.assertEqual|test_timeout|import logging import unittest import ssl from mock import patch from urllib3 import add_stderr_logger from urllib3.util import ( get_host, make_headers, split_first, parse_url, Timeout, Url, resolve_cert_reqs, ) from urllib3.exceptions import LocationParseError, TimeoutStateError # This n...
Timeout.DEFAULT_TIMEOUT)
250
8
urllib3/urllib3
train
88
4c70d76bac93c1941bacb7c7a068d4ad8efb2b19
train
test/with_dummyserver/test_https.py
train
urllib3/urllib3:test/with_dummyserver/test_https.py
74
12
self.assertTrue
test_verified_with_bad_ca_certs
import logging import ssl import sys import unittest import mock from nose.plugins.skip import SkipTest from dummyserver.testcase import HTTPSDummyServerTestCase from dummyserver.server import DEFAULT_CA, DEFAULT_CA_BAD, DEFAULT_CERTS from test import ( onlyPy3, onlyPy27OrNewer, onlyPy26OrOlder, requires_network...
'certificate verify failed' in str(e))
added
f28a7ad5c1c2d09b2b4b217ec3b020ee87d2a88577aa8aa7ec6a52e37ea497f3
self.assertTrue|test_verified_with_bad_ca_certs|import logging import ssl import sys import unittest import mock from nose.plugins.skip import SkipTest from dummyserver.testcase import HTTPSDummyServerTestCase from dummyserver.server import DEFAULT_CA, DEFAULT_CA_BAD, DEFAULT_CERTS from test import ( onlyPy3, onlyPy27O...
null
null
null
urllib3/urllib3
train
88
4c70d76bac93c1941bacb7c7a068d4ad8efb2b19
train
test/with_dummyserver/test_https.py
train
urllib3/urllib3:test/with_dummyserver/test_https.py
101
12
self.assertRaises
test_no_ssl
import logging import ssl import sys import unittest import mock from nose.plugins.skip import SkipTest from dummyserver.testcase import HTTPSDummyServerTestCase from dummyserver.server import DEFAULT_CA, DEFAULT_CA_BAD, DEFAULT_CERTS from test import ( onlyPy3, onlyPy27OrNewer, onlyPy26OrOlder, requires_network...
SSLError)
added
d6ef055776152ab61e00e8c574a0eca7300c2a639c3b779d1771298bacd65476
self.assertRaises|test_no_ssl|import logging import ssl import sys import unittest import mock from nose.plugins.skip import SkipTest from dummyserver.testcase import HTTPSDummyServerTestCase from dummyserver.server import DEFAULT_CA, DEFAULT_CA_BAD, DEFAULT_CERTS from test import ( onlyPy3, onlyPy27OrNewer, onlyPy26Or...
null
null
null
urllib3/urllib3
train
88
4c70d76bac93c1941bacb7c7a068d4ad8efb2b19
train
test/with_dummyserver/test_https.py
train
urllib3/urllib3:test/with_dummyserver/test_https.py
322
12
self.assertRaises
test_source_address_error
import logging import ssl import sys import unittest import mock from nose.plugins.skip import SkipTest from dummyserver.testcase import HTTPSDummyServerTestCase from dummyserver.server import DEFAULT_CA, DEFAULT_CA_BAD, DEFAULT_CERTS from test import ( onlyPy3, onlyPy27OrNewer, onlyPy26OrOlder, requires_network...
MaxRetryError)
added
04dfe6d118e9d3d4d7ca7a508053fe9316d116a19b21d3c1e945973b975562f4
self.assertRaises|test_source_address_error|import logging import ssl import sys import unittest import mock from nose.plugins.skip import SkipTest from dummyserver.testcase import HTTPSDummyServerTestCase from dummyserver.server import DEFAULT_CA, DEFAULT_CA_BAD, DEFAULT_CERTS from test import ( onlyPy3, onlyPy27OrNew...
null
null
null
urllib3/urllib3
train
88
4c70d76bac93c1941bacb7c7a068d4ad8efb2b19
train
test/with_dummyserver/test_https.py
train
urllib3/urllib3:test/with_dummyserver/test_https.py
343
8
self.assertRaises
test_ssl_version_as_short_string
import logging import ssl import sys import unittest import mock from nose.plugins.skip import SkipTest from dummyserver.testcase import HTTPSDummyServerTestCase from dummyserver.server import DEFAULT_CA, DEFAULT_CA_BAD, DEFAULT_CERTS from test import ( onlyPy3, onlyPy27OrNewer, onlyPy26OrOlder, requires_network...
SSLError)
added
25d12ce35ead65e4aeec091f3001909f8b5fa43a830cf6e16f50dbaf9e06a7f8
self.assertRaises|test_ssl_version_as_short_string|import logging import ssl import sys import unittest import mock from nose.plugins.skip import SkipTest from dummyserver.testcase import HTTPSDummyServerTestCase from dummyserver.server import DEFAULT_CA, DEFAULT_CA_BAD, DEFAULT_CERTS from test import ( onlyPy3, onlyPy...
null
null
null
urllib3/urllib3
train
89
649b27cc22c47ed528d5d52b79c38cd5de05e38a
train
test/test_util.py
train
urllib3/urllib3:test/test_util.py
182
8
self.assertEqual
test_make_headers
import logging import unittest import ssl from mock import patch from urllib3 import add_stderr_logger from urllib3.util import ( get_host, make_headers, split_first, parse_url, Timeout, Url, resolve_cert_reqs, ) from urllib3.exceptions import LocationParseError, TimeoutStateError # This ...
{'cache-control': 'no-cache'})
added
199a5c9c8efc23f0cfaa3f5d16cf154bb9df2c2384dd7d78fec6c1810df16ef1
self.assertEqual|test_make_headers|import logging import unittest import ssl from mock import patch from urllib3 import add_stderr_logger from urllib3.util import ( get_host, make_headers, split_first, parse_url, Timeout, Url, resolve_cert_reqs, ) from urllib3.exceptions import LocationParseError, TimeoutStateError # T...
null
null
null
urllib3/urllib3
train
89
649b27cc22c47ed528d5d52b79c38cd5de05e38a
train
test/test_util.py
train
urllib3/urllib3:test/test_util.py
201
8
self.assertTrue
test_add_stderr_logger
import logging import unittest import ssl from mock import patch from urllib3 import add_stderr_logger from urllib3.util import ( get_host, make_headers, split_first, parse_url, Timeout, Url, resolve_cert_reqs, ) from urllib3.exceptions import LocationParseError, TimeoutStateError # This ...
handler in logger.handlers)
added
ee1c905b7a9fe46ea5a04934b398abaee04cca466e5d1ba47672baf383058afd
self.assertTrue|test_add_stderr_logger|import logging import unittest import ssl from mock import patch from urllib3 import add_stderr_logger from urllib3.util import ( get_host, make_headers, split_first, parse_url, Timeout, Url, resolve_cert_reqs, ) from urllib3.exceptions import LocationParseError, TimeoutStateError...
null
null
null
urllib3/urllib3
train
89
649b27cc22c47ed528d5d52b79c38cd5de05e38a
train
test/test_util.py
train
urllib3/urllib3:test/test_util.py
256
8
self.assertEqual
test_timeout
import logging import unittest import ssl from mock import patch from urllib3 import add_stderr_logger from urllib3.util import ( get_host, make_headers, split_first, parse_url, Timeout, Url, resolve_cert_reqs, ) from urllib3.exceptions import LocationParseError, TimeoutStateError # This ...
Timeout.DEFAULT_TIMEOUT)
modified
971268dc2c622a4cc22c2c2bfb78f07bcf5625c537d92142cf6a175d630bcf3c
self.assertEqual|test_timeout|import logging import unittest import ssl from mock import patch from urllib3 import add_stderr_logger from urllib3.util import ( get_host, make_headers, split_first, parse_url, Timeout, Url, resolve_cert_reqs, ) from urllib3.exceptions import LocationParseError, TimeoutStateError # This n...
5)
258
8
urllib3/urllib3
train
89
649b27cc22c47ed528d5d52b79c38cd5de05e38a
train
test/test_util.py
train
urllib3/urllib3:test/test_util.py
293
8
self.assertRaises
test_timeout_elapsed
import logging import unittest import ssl from mock import patch from urllib3 import add_stderr_logger from urllib3.util import ( get_host, make_headers, split_first, parse_url, Timeout, Url, resolve_cert_reqs, ) from urllib3.exceptions import LocationParseError, TimeoutStateError # This ...
TimeoutStateError)
modified
55083ebbaebb5e1571b4eefbe63321d3ce26c83dadde3e575a3871fb8662d90c
self.assertRaises|test_timeout_elapsed|import logging import unittest import ssl from mock import patch from urllib3 import add_stderr_logger from urllib3.util import ( get_host, make_headers, split_first, parse_url, Timeout, Url, resolve_cert_reqs, ) from urllib3.exceptions import LocationParseError, TimeoutStateError...
TimeoutStateError)
292
8
urllib3/urllib3
train
90
432b895c3873a58b6c974a97d6f4e017707e08b1
train
test/with_dummyserver/test_socketlevel.py
train
urllib3/urllib3:test/with_dummyserver/test_socketlevel.py
199
8
self.assertRaises
test_delayed_body_read_timeout
from urllib3 import HTTPConnectionPool, HTTPSConnectionPool from urllib3.poolmanager import proxy_from_url from urllib3.exceptions import ( MaxRetryError, ProxyError, ReadTimeoutError, SSLError, ) from urllib3 import util from dummyserver.testcase import SocketDummyServerTestCase from ...
ReadTimeoutError)
added
e51725d6747809737446a111779bd3bc22c1a67a6f533e051570b12bfa2ac32b
self.assertRaises|test_delayed_body_read_timeout|from urllib3 import HTTPConnectionPool, HTTPSConnectionPool from urllib3.poolmanager import proxy_from_url from urllib3.exceptions import ( MaxRetryError, ProxyError, ReadTimeoutError, SSLError, ) from urllib3 import util from dummyserver.testcase import SocketDummyServe...
null
null
null
urllib3/urllib3
train
90
432b895c3873a58b6c974a97d6f4e017707e08b1
train
test/with_dummyserver/test_socketlevel.py
train
urllib3/urllib3:test/with_dummyserver/test_socketlevel.py
230
8
self.assertEqual
test_simple
from urllib3 import HTTPConnectionPool, HTTPSConnectionPool from urllib3.poolmanager import proxy_from_url from urllib3.exceptions import ( MaxRetryError, ProxyError, ReadTimeoutError, SSLError, ) from urllib3 import util from dummyserver.testcase import SocketDummyServerTestCase from ...
sorted([ b'GET http://google.com/ HTTP/1.1', b'Host: google.com', b'Accept-Encoding: identity', b'Accept: */*', b'', b'', ]))
added
2f25876040f61d390f280b9de2c6085e627df0169c7e9cf241bcc3c3aa812d84
self.assertEqual|test_simple|from urllib3 import HTTPConnectionPool, HTTPSConnectionPool from urllib3.poolmanager import proxy_from_url from urllib3.exceptions import ( MaxRetryError, ProxyError, ReadTimeoutError, SSLError, ) from urllib3 import util from dummyserver.testcase import SocketDummyServerTestCase from dummy...
null
null
null
urllib3/urllib3
train
90
432b895c3873a58b6c974a97d6f4e017707e08b1
train
test/with_dummyserver/test_socketlevel.py
train
urllib3/urllib3:test/with_dummyserver/test_socketlevel.py
270
8
self.assertTrue
test_headers
from urllib3 import HTTPConnectionPool, HTTPSConnectionPool from urllib3.poolmanager import proxy_from_url from urllib3.exceptions import ( MaxRetryError, ProxyError, ReadTimeoutError, SSLError, ) from urllib3 import util from dummyserver.testcase import SocketDummyServerTestCase from ...
b'For The Proxy: YEAH!\r\n' in r.data)
added
87108326d3ab541992edb5c6a177442bf0d64d84e88c7d1b9316c63c877afee3
self.assertTrue|test_headers|from urllib3 import HTTPConnectionPool, HTTPSConnectionPool from urllib3.poolmanager import proxy_from_url from urllib3.exceptions import ( MaxRetryError, ProxyError, ReadTimeoutError, SSLError, ) from urllib3 import util from dummyserver.testcase import SocketDummyServerTestCase from dummy...
null
null
null
urllib3/urllib3
train
90
432b895c3873a58b6c974a97d6f4e017707e08b1
train
test/with_dummyserver/test_socketlevel.py
train
urllib3/urllib3:test/with_dummyserver/test_socketlevel.py
335
8
self.assertRaises
test_ssl_failure_midway_through_conn
from urllib3 import HTTPConnectionPool, HTTPSConnectionPool from urllib3.poolmanager import proxy_from_url from urllib3.exceptions import ( MaxRetryError, ProxyError, ReadTimeoutError, SSLError, ) from urllib3 import util from dummyserver.testcase import SocketDummyServerTestCase from ...
SSLError)
added
ba0f2142d264a43347b012194d6af302e7ee6670a0735710db07f98029e1406a
self.assertRaises|test_ssl_failure_midway_through_conn|from urllib3 import HTTPConnectionPool, HTTPSConnectionPool from urllib3.poolmanager import proxy_from_url from urllib3.exceptions import ( MaxRetryError, ProxyError, ReadTimeoutError, SSLError, ) from urllib3 import util from dummyserver.testcase import SocketDumm...
null
null
null
urllib3/urllib3
train
91
ec5275eebaa9599defd9fa887668dec72b5c51e4
train
test/with_dummyserver/test_https.py
train
urllib3/urllib3:test/with_dummyserver/test_https.py
272
8
self.assertRaises
test_enhanced_timeout
import logging import ssl import sys import unittest import mock from nose.plugins.skip import SkipTest from dummyserver.testcase import HTTPSDummyServerTestCase from dummyserver.server import DEFAULT_CA, DEFAULT_CA_BAD, DEFAULT_CERTS from test import ( onlyPy3, onlyPy27OrNewer, onlyPy26OrOlder, requires_network...
ConnectTimeoutError)
modified
3f936db8190e3c22b5680ba077fb40c4d82a4a82d3762f2e06392639544b5c56
self.assertRaises|test_enhanced_timeout|import logging import ssl import sys import unittest import mock from nose.plugins.skip import SkipTest from dummyserver.testcase import HTTPSDummyServerTestCase from dummyserver.server import DEFAULT_CA, DEFAULT_CA_BAD, DEFAULT_CERTS from test import ( onlyPy3, onlyPy27OrNewer, ...
ConnectTimeoutError)
271
8
urllib3/urllib3
train
91
ec5275eebaa9599defd9fa887668dec72b5c51e4
train
test/with_dummyserver/test_https.py
train
urllib3/urllib3:test/with_dummyserver/test_https.py
323
12
self.assertRaises
test_source_address_error
import logging import ssl import sys import unittest import mock from nose.plugins.skip import SkipTest from dummyserver.testcase import HTTPSDummyServerTestCase from dummyserver.server import DEFAULT_CA, DEFAULT_CA_BAD, DEFAULT_CERTS from test import ( onlyPy3, onlyPy27OrNewer, onlyPy26OrOlder, requires_network...
MaxRetryError)
added
3d774d336a5c8daee0c8d3b3a7b4d6de0157e662d8b10f717e45c631e34431ac
self.assertRaises|test_source_address_error|import logging import ssl import sys import unittest import mock from nose.plugins.skip import SkipTest from dummyserver.testcase import HTTPSDummyServerTestCase from dummyserver.server import DEFAULT_CA, DEFAULT_CA_BAD, DEFAULT_CERTS from test import ( onlyPy3, onlyPy27OrNew...
null
null
null
urllib3/urllib3
train
91
ec5275eebaa9599defd9fa887668dec72b5c51e4
train
test/with_dummyserver/test_https.py
train
urllib3/urllib3:test/with_dummyserver/test_https.py
336
8
self.assertRaises
test_set_ssl_version_to_sslv3
import logging import ssl import sys import unittest import mock from nose.plugins.skip import SkipTest from dummyserver.testcase import HTTPSDummyServerTestCase from dummyserver.server import DEFAULT_CA, DEFAULT_CA_BAD, DEFAULT_CERTS from test import ( onlyPy3, onlyPy27OrNewer, onlyPy26OrOlder, requires_network...
SSLError)
added
2c5d7e6e1ba74da43339eab5e5fcecfbab72e58bab27792b0554eb55e02c7d71
self.assertRaises|test_set_ssl_version_to_sslv3|import logging import ssl import sys import unittest import mock from nose.plugins.skip import SkipTest from dummyserver.testcase import HTTPSDummyServerTestCase from dummyserver.server import DEFAULT_CA, DEFAULT_CA_BAD, DEFAULT_CERTS from test import ( onlyPy3, onlyPy27O...
null
null
null
urllib3/urllib3
train
91
ec5275eebaa9599defd9fa887668dec72b5c51e4
train
test/with_dummyserver/test_https.py
train
urllib3/urllib3:test/with_dummyserver/test_https.py
340
8
self.assertRaises
test_ssl_version_as_string
import logging import ssl import sys import unittest import mock from nose.plugins.skip import SkipTest from dummyserver.testcase import HTTPSDummyServerTestCase from dummyserver.server import DEFAULT_CA, DEFAULT_CA_BAD, DEFAULT_CERTS from test import ( onlyPy3, onlyPy27OrNewer, onlyPy26OrOlder, requires_network...
SSLError)
added
7e33824cad75c2eb5f070ceee7e069a63b83f2e3e966d61cd8eb35aa1c44e0b3
self.assertRaises|test_ssl_version_as_string|import logging import ssl import sys import unittest import mock from nose.plugins.skip import SkipTest from dummyserver.testcase import HTTPSDummyServerTestCase from dummyserver.server import DEFAULT_CA, DEFAULT_CA_BAD, DEFAULT_CERTS from test import ( onlyPy3, onlyPy27OrNe...
null
null
null
urllib3/urllib3
train
92
122dd99570b7faf1aec6c223b0f3352f699b1d65
train
test/with_dummyserver/test_socketlevel.py
train
urllib3/urllib3:test/with_dummyserver/test_socketlevel.py
388
8
self.assertRaises
test_ssl_failure_midway_through_conn
from urllib3 import HTTPConnectionPool, HTTPSConnectionPool from urllib3.poolmanager import proxy_from_url from urllib3.exceptions import ( MaxRetryError, ProxyError, ReadTimeoutError, SSLError, ) from urllib3 import util from dummyserver.testcase import SocketDummyServerTestCase from ...
SSLError)
added
75e5bcc188394c23f41aa427265b249c8b1e28feaca769ac2ec3235e8402f8e8
self.assertRaises|test_ssl_failure_midway_through_conn|from urllib3 import HTTPConnectionPool, HTTPSConnectionPool from urllib3.poolmanager import proxy_from_url from urllib3.exceptions import ( MaxRetryError, ProxyError, ReadTimeoutError, SSLError, ) from urllib3 import util from dummyserver.testcase import SocketDumm...
null
null
null
urllib3/urllib3
train
93
9ca3f3f9a4bdc505fd23da2264ef268e66f1d88a
train
test/with_dummyserver/test_https.py
train
urllib3/urllib3:test/with_dummyserver/test_https.py
62
12
self.assertTrue
test_invalid_common_name
import logging import ssl import sys import unittest import mock from nose.plugins.skip import SkipTest from dummyserver.testcase import HTTPSDummyServerTestCase from dummyserver.server import DEFAULT_CA, DEFAULT_CA_BAD, DEFAULT_CERTS from test import ( onlyPy26OrOlder, requires_network, TARPIT_HOST ) from u...
"doesn't match" in str(e))
modified
9980693ed4688aa8c700f6a140316c026f49a62485ed72ba97b583e414c5e53a
self.assertTrue|test_invalid_common_name|import logging import ssl import sys import unittest import mock from nose.plugins.skip import SkipTest from dummyserver.testcase import HTTPSDummyServerTestCase from dummyserver.server import DEFAULT_CA, DEFAULT_CA_BAD, DEFAULT_CERTS from test import ( onlyPy26OrOlder, requires...
"doesn't match" in str(e))
63
12