Commit Graph

17 Commits (783e545a67ee6088136023256ec0b5fbad07f17d)

Author SHA1 Message Date
Ville Skyttä 19d25cd901
Change config entry state to an enum ()
* Change config entry state to an enum

* Allow but deprecate EntryState str equality comparison

* Test fixes

* Rename to ConfigEntryState

* Remove str comparability backcompat

* Update new occurrences of strs cropped up during review
2021-05-20 19:19:20 +02:00
Maciej Bieniek bce5f8ee05
Improve AccuWeather type annotations ()
* Improve type annotations

* Remove unused argument

* Simplify state logic

* Fix uvindex state

* Fix type for logger

* Increase tests coverage

* Fix pylint arguments-differ error

* Suggested change

* Suggested change

* Remove unnecessary variable

* Remove unnecessary conditions

* Use int instead of list for forecast days

* Add enabled to sensor types dicts

* Fix request_remaining conversion and tests

* Run hassfest

* Suggested change

* Suggested change

* Do not use StateType
2021-05-19 09:37:16 +01:00
Ville Skyttä a396619251
Use disabled_by constants ()
Co-authored-by: J. Nick Koston <nick@koston.org>
2021-04-23 09:56:42 +02:00
Erik Montnemery 78b21b1ad1
Update tests a-b to use async_get() instead of async_get_registry() () 2021-03-09 14:24:34 +01:00
Maciej Bieniek 5d955eb039
Change update interval tests in AccuWeather integration () 2021-01-27 13:28:29 +01:00
Maciej Bieniek 14f5eb7305
Increase update interval in AccuWeather integration () 2021-01-20 15:17:53 -05:00
Franck Nijhof 65cf2fcb6f
Drop asynctest () 2021-01-01 22:31:56 +01:00
Abílio Costa 896f51fd82
Add Wind to Accuweather sensors () 2020-12-19 16:10:02 +01:00
Maciej Bieniek b294e1c98c
Add support for system health to AccuWeather integration () 2020-12-02 19:36:16 +01:00
springstan 30b94892c4
Use strings instead of f-strings for constants () 2020-11-09 10:09:53 +01:00
J. Nick Koston 6822190772
Fix unmocked https in the test suite () 2020-10-25 07:16:23 -05:00
springstan 06a133c3e9
Add and use length millimeters constant ()
* Add and use length millimeters constant

* Fix pylint error

* Fix broken accuweather sensor test
2020-09-22 21:09:17 -05:00
springstan d2b1918e9c
Drop UNIT_ prefix for percentage constant () 2020-09-05 21:09:14 +02:00
Franck Nijhof 1c2ebdf307
Upgrade black to 20.8b1 () 2020-08-27 13:56:20 +02:00
Maciej Bieniek a7e19c8896
Improve tests for AccuWeather integration ()
* Add more tests

* Add tests for sensor platform

* Add more tests

* More tests

* Simplify parsing of attributes

* Change Quality scale to platinum

* Patch the library in the manual update entity test

* Add unsupported condition icon test

* Do not patch _async_get_data

* Apply suggestions from code review

* Update config_flow.py

* Apply suggestions from code review

* Apply suggestions from code review

* Apply suggestions from code review

* Update tests/components/accuweather/test_weather.py

* Apply suggestions from code review

* Add return_value

Co-authored-by: Chris Talkington <chris@talkingtontech.com>
2020-08-09 09:21:36 -05:00
Maciej Bieniek 2b0914994d
Add changes from comments after merging AccuWeather ()
* Fix documentation url

* Return None instead STATE_UNKNOWN

* Invert forecast check

* Patch async_setup_entry in test_create entry

* Improve test name, docstring and add comment
2020-07-26 20:00:47 -05:00
Maciej Bieniek 581c4a4edd
Add AccuWeather integration ()
* Initial commit

* Fix strings

* Fix unit system

* Add config_flow tests

* Simplify tests

* More tests

* Update comment

* Fix pylint error

* Run gen_requirements_all

* Fix pyline error

* Round precipitation and precipitation probability

* Bump backend library

* Bump backend library

* Add undo update listener on unload

* Add translation key for invalid_api_key

* Remove entity_registry_enabled_default property

* Suggested change

* Bump library
2020-07-24 15:59:15 -05:00