hass-core/tests/components/whirlpool/__init__.py
Abílio Costa c869b78ac1
Add Whirlpool integration (#48346)
* Add Whirlpool integration

* Apply suggestions from code review

Co-authored-by: Paulus Schoutsen <paulus@home-assistant.io>

* Apply suggestions from code review

* Fix lint

* Fix lint and tests

* Apply suggestions from code review

Co-authored-by: J. Nick Koston <nick@koston.org>

* Use dict lookups

* Lint

* Apply code changes from PR review

* Do real integration setup in tests

* Apply suggestions from review & fix test

* Replace get with array operator

* Add suggestions from code review

* Rename test var

Co-authored-by: Paulus Schoutsen <paulus@home-assistant.io>
Co-authored-by: J. Nick Koston <nick@koston.org>
2021-09-13 10:02:34 -10:00

23 lines
697 B
Python

"""Tests for the Whirlpool Sixth Sense integration."""
from homeassistant.components.whirlpool.const import DOMAIN
from homeassistant.const import CONF_PASSWORD, CONF_USERNAME
from homeassistant.core import HomeAssistant
from tests.common import MockConfigEntry
async def init_integration(hass: HomeAssistant) -> MockConfigEntry:
"""Set up the Whirlpool integration in Home Assistant."""
entry = MockConfigEntry(
domain=DOMAIN,
data={
CONF_USERNAME: "nobody",
CONF_PASSWORD: "qwerty",
},
)
entry.add_to_hass(hass)
await hass.config_entries.async_setup(entry.entry_id)
await hass.async_block_till_done()
return entry