Commit Graph

15 Commits (a224b668d7deee92a470ee82b5d4f24f6c2cb430)

Author SHA1 Message Date
Joost Lekkerkerker fe66c3414b
Implement data coordinator for LastFM (#96942)
Co-authored-by: G Johansson <goran.johansson@shiftit.se>
2023-07-24 19:39:46 +02:00
Joost Lekkerkerker dd6cd0096a
Improve code coverage for LastFM (#97012)
* Improve code coverage for LastFM

* Revert introduced bug
2023-07-23 20:09:16 +02:00
Joost Lekkerkerker 9b717cb84f
Use snapshot testing in LastFM (#97009) 2023-07-22 12:47:26 +02:00
Joost Lekkerkerker b3a001996d
Improve coverage for LastFM (#93661)
* Improve coverage for LastFM

* Improve tests

* Improve tests
2023-06-08 16:55:16 -04:00
Joost Lekkerkerker 20449d1f01
Catch exception when user has no lastfm friends (#94235) 2023-06-08 16:08:18 +02:00
Joost Lekkerkerker a96215bf2e
Lastfm config flow (#92299)
* Move constant values to separate file

* Move constant values to separate file

* Add config flow to lastfm

* Add tests

* Add config flow to lastfm

* Add tests

* Add tests

* Add tests

* Add extra form for main user and autofill with friends

* Add extra form for main user and autofill with friends

* Add extra form for main user and autofill with friends

* Add extra form for main user and autofill with friends

* Add OptionsFlow

* Add tests

* Fix feedback

* Fix feedback

* Fix feedback

* Fix feedback

* Fix test

* Apply suggestions from code review

Co-authored-by: G Johansson <goran.johansson@shiftit.se>

* Update config_flow.py

* Update config_flow.py

* Update config_flow.py

* Update homeassistant/components/lastfm/config_flow.py

Co-authored-by: G Johansson <goran.johansson@shiftit.se>

* Add tests

* Cleanup

* Update config_flow.py

* Update config_flow.py

* Update config_flow.py

* Fix test

* Fix feedback

* Codeowner lastfm

* Fix feedback

* Fix feedback

* Parametrize errors

* Parametrize errors

* Parametrize errors

* Finish tests

---------

Co-authored-by: G Johansson <goran.johansson@shiftit.se>
2023-05-25 14:48:16 +02:00
Joost Lekkerkerker cd52e05075
Move lastfm constants to separate file (#92289) 2023-04-30 18:09:02 +02:00
Joost Lekkerkerker 88f5f04be8
Refactor LastFM to use shorthand attributes (#91606)
* Preliminary PR for the coordinator

* Preliminary PR for the coordinator

* Preliminary PR for the coordinator

* Apply suggestions from code review

Co-authored-by: epenet <6771947+epenet@users.noreply.github.com>

* Preliminary PR for the coordinator

* Preliminary PR for the coordinator

* Preliminary PR for the coordinator

* Preliminary PR for the coordinator

* Preliminary PR for the coordinator

* Preliminary PR for the coordinator

* Preliminary PR for the coordinator

* Apply feedback

* Apply feedback

* Apply feedback

* Apply feedback

* Apply feedback

* Update homeassistant/components/lastfm/sensor.py

Co-authored-by: epenet <6771947+epenet@users.noreply.github.com>

* Update homeassistant/components/lastfm/sensor.py

Co-authored-by: epenet <6771947+epenet@users.noreply.github.com>

* Apply feedback

* Apply feedback

* Fix tests

* Update homeassistant/components/lastfm/sensor.py

Co-authored-by: epenet <6771947+epenet@users.noreply.github.com>

* Fix tests

* Fix feedback

---------

Co-authored-by: epenet <6771947+epenet@users.noreply.github.com>
2023-04-19 14:13:43 +02:00
epenet ea11a30a35
Add type hints to integration tests (part 13) (#87998) 2023-02-13 14:38:37 +01:00
Aarni Koskela e4c73259f7
Configure autoflake for pre-commit (#82414) 2022-11-22 08:10:36 +01:00
Malachi Soord 0656407561
Upgrade pylast from 4.2.0 to 4.2.1 (#56015)
* Upgrade pylast from 4.2.0 to 4.2.1

* Fix test

* Use MockNetwork

* Tidy

* Fix lint
2021-09-16 07:00:25 +02:00
Franck Nijhof 65cf2fcb6f
Drop asynctest (#44746) 2021-01-01 22:31:56 +01:00
Paulus Schoutsen 276f3afb00
Do async_setup_platform in background (#36244)
Co-authored-by: J. Nick Koston <nick@koston.org>
2020-05-31 22:18:30 -07:00
Paulus Schoutsen 2af984917e
Use asynctest-mock in most places (#35109)
* Use asynctest-mock in most places

* Fix broken patch in pilight
2020-05-03 11:27:19 -07:00
Malachi Soord 3f0936f068
Prevent last.fm errors with None (#33446) 2020-04-05 18:03:13 +02:00