@@ -135,11 +135,6 @@ async def setup_legacy_app(
135135 """Create mock webserver for Smile to interface with."""
136136 app = aiohttp .web .Application ()
137137
138- # if fail_auth:
139- # app.router.add_get("/{tail:.*}", self.smile_fail_auth)
140- # app.router.add_route("PUT", "/{tail:.*}", self.smile_fail_auth)
141- # return app
142-
143138 app .router .add_get ("/core/appliances" , self .smile_appliances )
144139 app .router .add_get ("/core/domain_objects" , self .smile_domain_objects )
145140 app .router .add_get ("/core/modules" , self .smile_modules )
@@ -474,16 +469,6 @@ async def connect_legacy_wrapper(
474469 self , raise_timeout = False , fail_auth = False , stretch = False
475470 ):
476471 """Wrap connect to try negative testing before positive testing."""
477- # if fail_auth:
478- # try:
479- # _LOGGER.warning("Connecting to device with invalid credentials:")
480- # await self.connect_legacy(fail_auth=fail_auth)
481- # _LOGGER.error(" - invalid credentials not handled") # pragma: no cover
482- # raise self.ConnectError # pragma: no cover
483- # except pw_exceptions.InvalidAuthentication as exc:
484- # _LOGGER.info(" + successfully aborted on credentials missing.")
485- # raise pw_exceptions.InvalidAuthentication from exc
486-
487472 if raise_timeout :
488473 _LOGGER .warning ("Connecting to device exceeding timeout in handling:" )
489474 return await self .connect_legacy (raise_timeout = True )
0 commit comments