Replace assert_lists_same with pytest_unordered in integrations a-f (#94900)

This commit is contained in:
Erik Montnemery
2023-06-20 20:22:31 +02:00
committed by GitHub
parent fd822bce56
commit 6a29ed8caa
19 changed files with 60 additions and 60 deletions
@@ -2,6 +2,7 @@
from __future__ import annotations
import pytest
from pytest_unordered import unordered
from homeassistant.components import automation
from homeassistant.components.button import DOMAIN
@@ -13,7 +14,6 @@ from homeassistant.setup import async_setup_component
from tests.common import (
MockConfigEntry,
assert_lists_same,
async_get_device_automations,
async_mock_service,
)
@@ -53,7 +53,7 @@ async def test_get_triggers(
triggers = await async_get_device_automations(
hass, DeviceAutomationType.TRIGGER, device_entry.id
)
assert_lists_same(triggers, expected_triggers)
assert triggers == unordered(expected_triggers)
@pytest.mark.parametrize(
@@ -101,7 +101,7 @@ async def test_get_triggers_hidden_auxiliary(
triggers = await async_get_device_automations(
hass, DeviceAutomationType.TRIGGER, device_entry.id
)
assert_lists_same(triggers, expected_triggers)
assert triggers == unordered(expected_triggers)
async def test_if_fires_on_state_change(hass: HomeAssistant, calls) -> None: