Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Refactor Netatmo integration #29851

Merged
merged 58 commits into from
Jan 11, 2020
Merged
Changes from 1 commit
Commits
Show all changes
58 commits
Select commit Hold shift + click to select a range
ad9b859
Refactor to use ids in data class
cgtobi Nov 22, 2019
ccaeee1
Use station_id
cgtobi Nov 22, 2019
2e7a5c7
Refactor Netatmo to use oauth
cgtobi Nov 28, 2019
22dc311
Remove old code
cgtobi Nov 28, 2019
0139896
Clean up
cgtobi Nov 28, 2019
f5ea022
Clean up
cgtobi Nov 28, 2019
451d727
Clean up
cgtobi Nov 28, 2019
70b5a6e
Refactor binary sensor
cgtobi Dec 9, 2019
23d44ab
Add initial light implementation
cgtobi Dec 9, 2019
17f42c8
Add discovery
cgtobi Dec 9, 2019
583c0b6
Add set schedule service back in
cgtobi Dec 9, 2019
43ba309
Add discovery via homekit
cgtobi Dec 10, 2019
724bc98
More work on the light
cgtobi Dec 10, 2019
ba19600
Fix set schedule service
cgtobi Dec 11, 2019
e6d27d1
Clean up
cgtobi Dec 11, 2019
f2e5b94
Remove unnecessary code
cgtobi Dec 12, 2019
d5e0577
Add support for multiple entities/accounts
cgtobi Dec 12, 2019
0448949
Fix MANUFACTURER typo
cgtobi Dec 12, 2019
7e0f2b7
Remove multiline inline if statement
cgtobi Dec 12, 2019
10d30c7
Only add tags when camera type is welcome
cgtobi Dec 12, 2019
750d17f
Remove on/off as it's currently broken
cgtobi Dec 12, 2019
2038846
Fix camera turn_on/off
cgtobi Dec 12, 2019
756f31f
Fix debug message
cgtobi Dec 12, 2019
cc18203
Refactor some camera code
cgtobi Dec 12, 2019
5a40241
Refactor camera methods
cgtobi Dec 12, 2019
622eedb
Remove old code
cgtobi Dec 12, 2019
1b59e19
Rename method
cgtobi Dec 12, 2019
c2536fa
Update persons regularly
cgtobi Dec 12, 2019
e80e457
Remove unused code
cgtobi Dec 12, 2019
f3c743c
Refactor method
cgtobi Dec 12, 2019
7f72177
Fix isort
cgtobi Dec 12, 2019
4216de9
Add english strings
cgtobi Dec 13, 2019
c560a74
Catch NoDevice exception
cgtobi Dec 13, 2019
159be98
Fix unique id and only add sensors for tags if present
cgtobi Dec 13, 2019
85f767e
Address comments
cgtobi Dec 13, 2019
fe41285
Remove ToDo comment
cgtobi Dec 13, 2019
e37f2e0
Add set_light_auto back in
cgtobi Dec 17, 2019
cb5068b
Add debug info
cgtobi Dec 17, 2019
21eb950
Fix multiple camera issue
cgtobi Dec 17, 2019
90fbf8f
Move camera light service to camera
cgtobi Dec 18, 2019
03b7a54
Only allow camera entities
cgtobi Dec 19, 2019
f18a227
Make test pass
cgtobi Dec 20, 2019
eb50f2b
Upgrade pyatmo module to 3.2.0
cgtobi Jan 2, 2020
038dbc5
Update requirements
cgtobi Jan 2, 2020
7acc035
Remove list comprehension
cgtobi Jan 2, 2020
1fbcafd
Remove guideline violating code
cgtobi Jan 2, 2020
07e52a7
Remove stale code
cgtobi Jan 2, 2020
a8d182a
Rename devices to entities
cgtobi Jan 2, 2020
ec72262
Remove light platform
cgtobi Jan 3, 2020
7c066d1
Remove commented code
cgtobi Jan 3, 2020
0ec0568
Exclude files from coverage
cgtobi Jan 3, 2020
aee09d3
Remove unused code
cgtobi Jan 3, 2020
dbfae85
Fix unique id
cgtobi Jan 3, 2020
fa10785
Address comments
cgtobi Jan 9, 2020
62b6bfd
Fix comments
cgtobi Jan 9, 2020
86124f0
Exclude sensor as well
cgtobi Jan 9, 2020
5c573bf
Add another test
cgtobi Jan 9, 2020
f32424e
Use core interfaces
cgtobi Jan 10, 2020
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Use core interfaces
  • Loading branch information
cgtobi committed Jan 10, 2020
commit f32424e1cbf16c06082474fafdbd8ee3a347a889
10 changes: 7 additions & 3 deletions tests/components/netatmo/test_config_flow.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,12 +21,16 @@ async def test_abort_if_existing_entry(hass):
flow = config_flow.NetatmoFlowHandler()
flow.hass = hass

result = await flow.async_step_user()
result = await hass.config_entries.flow.async_init(
"netatmo", context={"source": config_entries.SOURCE_USER}
)
assert result["type"] == data_entry_flow.RESULT_TYPE_ABORT
assert result["reason"] == "already_setup"

result = await flow.async_step_homekit(
{"host": "0.0.0.0", "properties": {"id": "aa:bb:cc:dd:ee:ff"}}
result = await hass.config_entries.flow.async_init(
"netatmo",
context={"source": "homekit"},
data={"host": "0.0.0.0", "properties": {"id": "aa:bb:cc:dd:ee:ff"}},
)
assert result["type"] == data_entry_flow.RESULT_TYPE_ABORT
assert result["reason"] == "already_setup"
Expand Down