Add config flow for Tuya (#35422)

* Added Tuya config flow

* Added test config_flow

* Fixed log error message

* Add test requirements

* Lint Fix

* Fix Black formatting

* Added pylint directive

Added pylint:disable=unused-import in config_flow.py

* Implementation requested changes

* Update CodeOwners

* Removed device registry cleanup

* Force checks

* Force checks

* Fix implemetation

- Set config schema "deprecated"
- Removed async from update_callback

* Updating test

* Fix formatting

* Config Flow test fix

- mock out async_setup and async_setup_entry

* Fix formatting
This commit is contained in:
ollo69 authored and GitHub committed 2020-05-10 22:01:00 -05:00
1 parent c69d4943a5
commit b3ee54b124
17 files changed
+757 -210

No files matched your search

@@ -0,0 +1,26 @@
{
"config": {
"flow_title": "Tuya configuration",
"step": {
"user": {
"title": "Tuya",
"description": "Enter your Tuya credential.",
"data": {
"country_code": "Your account country code (e.g., 1 for USA or 86 for China)",
"password": "[%key:common::config_flow::data::password%]",
"platform": "The app where your account register",
"username": "[%key:common::config_flow::data::username%]"
}
}
},
"abort": {
"already_in_progress": "Tuya configuration is already in progress.",
"auth_failed": "[%key:common::config_flow::error::invalid_auth%]",
"conn_error": "[%key:common::config_flow::error::cannot_connect%]",
"single_instance_allowed": "[%key:common::config_flow::abort::single_instance_allowed%]"
},
"error": {
"auth_failed": "[%key:common::config_flow::error::invalid_auth%]"
}
}
}