MCPcopy
hub / github.com/urllib3/urllib3 / request

Method request

test/with_dummyserver/test_socketlevel.py:1617–1631  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

1615 fingerprint = "A0:C4:A7:46:00:ED:A7:2D:C0:BE:CB:9A:8C:B6:07:CA:58:EE:74:5E"
1616
1617 def request() -> None:
1618 pool = HTTPSConnectionPool(
1619 self.host,
1620 self.port,
1621 assert_fingerprint=fingerprint,
1622 cert_reqs="CERT_NONE",
1623 )
1624 try:
1625 timeout = Timeout(connect=LONG_TIMEOUT, read=SHORT_TIMEOUT)
1626 response = pool.urlopen(
1627 "GET", "/", preload_content=False, retries=0, timeout=timeout
1628 )
1629 response.read()
1630 finally:
1631 pool.close()
1632
1633 with pytest.raises(MaxRetryError) as cm:
1634 request()

Callers 15

test_max_connectionsMethod · 0.45
_testMethod · 0.45
test_pool_sizeMethod · 0.45
test_assert_same_hostMethod · 0.45
test_basic_requestMethod · 0.45
test_local_dnsMethod · 0.45
test_socket_timeoutMethod · 0.45

Calls 5

HTTPSConnectionPoolClass · 0.90
TimeoutClass · 0.90
urlopenMethod · 0.45
readMethod · 0.45
closeMethod · 0.45

Tested by

no test coverage detected