* Add ClimaCell v4 API support * fix tests * use constants * fix logic and update tests * revert accidental changes and enable hourly and nowcast forecast entities in test * use variable instead of accessing dictionary multiple times * only grab necessary fields * add _translate_condition method ot base class * bump pyclimacell again to fix bug * switch typehints back to new format * more typehint fixes * fix tests * revert merge conflict change * handle 'migration' in async_setup_entry so we don't have to bump config entry versions * parametrize timestep test
38 lines
656 B
Python
38 lines
656 B
Python
"""Constants for climacell tests."""
|
|
|
|
from homeassistant.const import (
|
|
CONF_API_KEY,
|
|
CONF_API_VERSION,
|
|
CONF_LATITUDE,
|
|
CONF_LONGITUDE,
|
|
CONF_NAME,
|
|
)
|
|
|
|
API_KEY = "aa"
|
|
|
|
MIN_CONFIG = {
|
|
CONF_API_KEY: API_KEY,
|
|
}
|
|
|
|
V1_ENTRY_DATA = {
|
|
CONF_NAME: "ClimaCell",
|
|
CONF_API_KEY: API_KEY,
|
|
CONF_LATITUDE: 80,
|
|
CONF_LONGITUDE: 80,
|
|
}
|
|
|
|
API_V3_ENTRY_DATA = {
|
|
CONF_NAME: "ClimaCell",
|
|
CONF_API_KEY: API_KEY,
|
|
CONF_LATITUDE: 80,
|
|
CONF_LONGITUDE: 80,
|
|
CONF_API_VERSION: 3,
|
|
}
|
|
|
|
API_V4_ENTRY_DATA = {
|
|
CONF_NAME: "ClimaCell",
|
|
CONF_API_KEY: API_KEY,
|
|
CONF_LATITUDE: 80,
|
|
CONF_LONGITUDE: 80,
|
|
CONF_API_VERSION: 4,
|
|
}
|