Add sensors to fetch Habitica tasks (#38910)

* Adding sensors to fetch habitica tasks

* PR changes and rebase

* Fixing pylint

* Fixing failed test dependancy

* Generating requirements

* Apply suggestions from code review

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>

* PR changes

* Update homeassistant/components/habitica/config_flow.py

Thank you, @MartinHjelmare

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>

* PR Changes

* Fix failing test

* Update tests/components/habitica/test_config_flow.py

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>

* Fixing linting and imports

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
This commit is contained in:
Ilja Leiko 2021-02-17 09:04:11 +01:00 committed by GitHub
parent 56f32196bd
commit 8c72cb6163
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
13 changed files with 549 additions and 96 deletions

View file

@ -0,0 +1,14 @@
"""Constants for the habitica integration."""
from homeassistant.const import CONF_NAME, CONF_PATH
CONF_API_USER = "api_user"
DEFAULT_URL = "https://habitica.com"
DOMAIN = "habitica"
SERVICE_API_CALL = "api_call"
ATTR_NAME = CONF_NAME
ATTR_PATH = CONF_PATH
ATTR_ARGS = "args"
EVENT_API_CALL_SUCCESS = f"{DOMAIN}_{SERVICE_API_CALL}_success"