Add config flow to gogogate2 component (#34709)

* Add config flow to gogogate2 component.

* Using a more stable gogogate api.

* Getting config flows working better by using different downstream library.

* Fixing options not getting default values.
Adding availability to cover entity.

* Simplifying return types of function.

* Address PR feedback.

* Making user config flow not abort.

* Using DataUpdateCoordinator.

* Addressing PR feedback.

* Using standard method for using hass.data

* Split auth fail test into separate tests.
This commit is contained in:
Robert Van Gorkom 2020-05-16 08:53:11 -07:00 committed by GitHub
parent 6e0359efa6
commit 11b786a4fc
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
18 changed files with 1189 additions and 69 deletions

View file

@ -0,0 +1,17 @@
"""Fixtures for tests."""
from mock import patch
import pytest
from homeassistant.core import HomeAssistant
from .common import ComponentFactory
@pytest.fixture()
def component_factory(hass: HomeAssistant):
"""Return a factory for initializing the gogogate2 api."""
with patch(
"homeassistant.components.gogogate2.common.GogoGate2Api"
) as gogogate2_api_mock:
yield ComponentFactory(hass, gogogate2_api_mock)