mirror of
https://github.com/home-assistant/supervisor.git
synced 2025-07-23 00:56:29 +00:00
Check for duplicate data disks only when the OS is available (#6025)
* Check for duplicate data disks only when the OS is available Supervised installations do not have a specific data disk, so only check for duplicate data disks on Home Assistant OS. * Enable OS for multiple data disks check test
This commit is contained in:
parent
c617358855
commit
780ae1e15c
@ -21,6 +21,9 @@ class CheckMultipleDataDisks(CheckBase):
|
|||||||
|
|
||||||
async def run_check(self) -> None:
|
async def run_check(self) -> None:
|
||||||
"""Run check if not affected by issue."""
|
"""Run check if not affected by issue."""
|
||||||
|
if not self.sys_os.available:
|
||||||
|
return
|
||||||
|
|
||||||
for block_device in self.sys_dbus.udisks2.block_devices:
|
for block_device in self.sys_dbus.udisks2.block_devices:
|
||||||
if self._block_device_has_name_issue(block_device):
|
if self._block_device_has_name_issue(block_device):
|
||||||
self.sys_resolution.create_issue(
|
self.sys_resolution.create_issue(
|
||||||
|
@ -33,6 +33,7 @@ async def test_base(coresys: CoreSys):
|
|||||||
assert multiple_data_disks.enabled
|
assert multiple_data_disks.enabled
|
||||||
|
|
||||||
|
|
||||||
|
@pytest.mark.usefixtures("os_available")
|
||||||
async def test_check(coresys: CoreSys, sda1_block_service: BlockService):
|
async def test_check(coresys: CoreSys, sda1_block_service: BlockService):
|
||||||
"""Test check."""
|
"""Test check."""
|
||||||
multiple_data_disks = CheckMultipleDataDisks(coresys)
|
multiple_data_disks = CheckMultipleDataDisks(coresys)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user