remove need for mypy override

This commit is contained in:
meejah 2024-11-18 13:34:46 -07:00
parent 7417cdb01c
commit 074b6a6947

View File

@ -27,7 +27,8 @@ from queue import Queue
from pycddl import ValidationError as CDDLValidationError
from hypothesis import assume, given, strategies as st, settings as hypothesis_settings
from fixtures import Fixture, TempDir, MonkeyPatch
from treq.testing import StubTreq
from treq.client import HTTPClient
from treq.testing import StubTreq, RequestTraversalAgent
from klein import Klein
from hyperlink import DecodedURL
from collections_extended import RangeMap
@ -714,9 +715,11 @@ class GenericHTTPAPITests(SyncTestCase):
If nothing is given in the ``Authorization`` header at all an
``Unauthorized`` response is returned.
"""
client = StubTreq(self.http.http_server.get_resource())
client = HTTPClient(
RequestTraversalAgent(self.http.http_server.get_resource())
)
response = self.http.result_of_with_flush(
client.request( # type: ignore[attr-defined]
client.request(
"GET",
"http://127.0.0.1/storage/v1/version",
),