1
0
mirror of https://github.com/home-assistant/core.git synced 2025-12-24 21:06:19 +00:00

Test fixes (#22911)

* Fix light tests [skip ci]

* Fix tests/common

* Fix some mqtt tests [skip ci]

* Fix tests and component manifests which have only one platform

* Fix more tests and manifests

* Fix demo/notify tests

* Rollback test for demo.geo_location
This commit is contained in:
Paulus Schoutsen
2019-04-08 23:16:55 -07:00
committed by GitHub
parent 1a05f7b04d
commit 590eead128
20 changed files with 68 additions and 48 deletions

View File

@@ -36,9 +36,8 @@ class TestMQTT:
assert setup_component(self.hass, mqtt.DOMAIN, {
mqtt.DOMAIN: {CONF_PASSWORD: password},
})
self.hass.block_till_done()
assert mock_mqtt.called
from pprint import pprint
pprint(mock_mqtt.mock_calls)
assert mock_mqtt.mock_calls[1][2]['username'] == 'homeassistant'
assert mock_mqtt.mock_calls[1][2]['password'] == password
@@ -61,9 +60,8 @@ class TestMQTT:
'http': {'api_password': 'http_secret'},
mqtt.DOMAIN: {CONF_PASSWORD: password},
})
self.hass.block_till_done()
assert mock_mqtt.called
from pprint import pprint
pprint(mock_mqtt.mock_calls)
assert mock_mqtt.mock_calls[1][2]['username'] == 'homeassistant'
assert mock_mqtt.mock_calls[1][2]['password'] == password