Cleanup source_type type hints in device tracker components (#126592)

This commit is contained in:
epenet
2024-09-24 08:54:55 +02:00
committed by GitHub
parent 61ff40c299
commit 2df6824856
6 changed files with 7 additions and 7 deletions
+1 -1
View File
@@ -69,7 +69,7 @@ class MockScannerEntity(ScannerEntity):
self._mac_address = "ad:de:ef:be:ed:fe"
@property
def source_type(self):
def source_type(self) -> SourceType:
"""Return the source type, eg gps or router, of the device."""
return SourceType.ROUTER
@@ -162,7 +162,7 @@ class MockTrackerEntity(TrackerEntity):
return self._battery_level
@property
def source_type(self) -> SourceType | str:
def source_type(self) -> SourceType:
"""Return the source type, eg gps or router, of the device."""
return SourceType.GPS
@@ -249,7 +249,7 @@ class MockScannerEntity(ScannerEntity):
return False
@property
def source_type(self) -> SourceType | str:
def source_type(self) -> SourceType:
"""Return the source type, eg gps or router, of the device."""
return SourceType.ROUTER