* Initial commit for Dexcom integration * Dexcom config flow testing * Clarify errors during setup * Resolve minor test issues * Update sensor availability, resolve linting issues * Add sensor tests * Remove title due to 0.109, add abort * >94.97% codecov/patch * Move .translations/ to translations/ * Add constants for servers and unit of measurements * Bump pydexcom version * Updated domain schema, Dexcom creation * Support for different units of measurement * Update tests * Remove empty items from manifest Co-authored-by: Martin Hjelmare <marhje52@gmail.com> * Raise UpdateFailed if fetching new session fails * Switch everything over to required * Simplify state information * Simplify async_on_remove * Pydexcom package now handles fetching new session * Only allow config flow * Remove ternary operator * Bump version, pydexcom handling session refresh * Using common strings * Import from test.async_mock * Shorten variable names * Resolve tests after removing yaml support * Return false if credentials are invalid * Available seems to handle if data is empty * Now using option flow, remove handling import * Add fixture for JSON returned from API * Overhaul testing * Revise update options * Bump pydexcom version * Combat listener repetition * Undo update listener using callback * Change sensor availability to use last_update_success * Update sensor availability and tests * Rename test Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
30 lines
559 B
Python
30 lines
559 B
Python
"""Constants for the Dexcom integration."""
|
|
|
|
DOMAIN = "dexcom"
|
|
PLATFORMS = ["sensor"]
|
|
|
|
GLUCOSE_VALUE_ICON = "mdi:diabetes"
|
|
|
|
GLUCOSE_TREND_ICON = [
|
|
"mdi:help",
|
|
"mdi:arrow-up-thick",
|
|
"mdi:arrow-up",
|
|
"mdi:arrow-top-right",
|
|
"mdi:arrow-right",
|
|
"mdi:arrow-bottom-right",
|
|
"mdi:arrow-down",
|
|
"mdi:arrow-down-thick",
|
|
"mdi:help",
|
|
"mdi:alert-circle-outline",
|
|
]
|
|
|
|
MMOL_L = "mmol/L"
|
|
MG_DL = "mg/dL"
|
|
|
|
CONF_SERVER = "server"
|
|
|
|
SERVER_OUS = "EU"
|
|
SERVER_US = "US"
|
|
|
|
COORDINATOR = "coordinator"
|
|
UNDO_UPDATE_LISTENER = "undo_update_listener"
|