Skip to content

Commit 7b52775

Browse files
committed
address feedback
1 parent 63f33f2 commit 7b52775

1 file changed

Lines changed: 3 additions & 9 deletions

File tree

packages/gapic-generator/tests/system/conftest.py

Lines changed: 3 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,6 @@
1919
import pytest
2020
import pytest_asyncio
2121
from requests.adapters import HTTPAdapter
22-
from urllib3.poolmanager import PoolManager
2322

2423
from typing import Sequence, Tuple
2524

@@ -473,14 +472,9 @@ async def intercepted_echo_grpc_async(use_mtls, use_tls):
473472

474473
class HostNameIgnoringAdapter(HTTPAdapter):
475474
"""Custom HTTPAdapter that disables hostname verification for local self-signed certs."""
476-
def init_poolmanager(self, connections, maxsize, block=False, **pool_kwargs):
477-
self.poolmanager = PoolManager(
478-
num_pools=connections,
479-
maxsize=maxsize,
480-
block=block,
481-
assert_hostname=False,
482-
**pool_kwargs
483-
)
475+
def cert_verify(self, conn, url, verify, cert):
476+
super().cert_verify(conn, url, verify, cert)
477+
conn.assert_hostname = False
484478

485479

486480
@pytest.fixture

0 commit comments

Comments
 (0)