Reload mobile app notify service upon device name change, add device name to all webhook logs (#39364)

* Add device name to all webhook logs to help with multiple devices

* Reload notifications when we update the registration, update from rebase

* Make hassfest happy

* Adjust caplog test to accomodate log message change

Co-authored-by: J. Nick Koston <nick@koston.org>
This commit is contained in:
Daniel Shokouhi 2020-08-28 13:13:43 -07:00 committed by GitHub
parent c163d4a4b5
commit d587f134ca
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
3 changed files with 28 additions and 13 deletions

View file

@ -122,7 +122,7 @@ async def test_sensor_id_no_dupes(hass, create_registrations, webhook_client, ca
assert reg_json == {"success": True}
await hass.async_block_till_done()
assert "Re-register existing sensor" not in caplog.text
assert "Re-register" not in caplog.text
entity = hass.states.get("sensor.test_1_battery_state")
assert entity is not None
@ -143,7 +143,7 @@ async def test_sensor_id_no_dupes(hass, create_registrations, webhook_client, ca
assert dupe_reg_json == {"success": True}
await hass.async_block_till_done()
assert "Re-register existing sensor" in caplog.text
assert "Re-register" in caplog.text
entity = hass.states.get("sensor.test_1_battery_state")
assert entity is not None