Fix alarm control panel tests (#24586)

This commit is contained in:
Paulus Schoutsen 2019-06-17 20:23:12 -07:00 committed by GitHub
parent 73008885c8
commit f3e4e8dce8
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -66,8 +66,7 @@ async def test_arm_home_no_pending_when_code_not_req(hass):
assert STATE_ALARM_DISARMED == \
hass.states.get(entity_id).state
common.async_alarm_arm_home(hass, 0)
await hass.async_block_till_done()
await common.async_alarm_arm_home(hass, 0)
assert STATE_ALARM_ARMED_HOME == \
hass.states.get(entity_id).state
@ -172,8 +171,7 @@ async def test_arm_away_no_pending_when_code_not_req(hass):
assert STATE_ALARM_DISARMED == \
hass.states.get(entity_id).state
common.async_alarm_arm_away(hass, 0, entity_id)
await hass.async_block_till_done()
await common.async_alarm_arm_away(hass, 0, entity_id)
assert STATE_ALARM_ARMED_AWAY == \
hass.states.get(entity_id).state
@ -301,8 +299,7 @@ async def test_arm_night_no_pending_when_code_not_req(hass):
assert STATE_ALARM_DISARMED == \
hass.states.get(entity_id).state
common.async_alarm_arm_night(hass, 0)
await hass.async_block_till_done()
await common.async_alarm_arm_night(hass, 0)
assert STATE_ALARM_ARMED_NIGHT == \
hass.states.get(entity_id).state
@ -1221,8 +1218,7 @@ async def test_arm_custom_bypass_no_pending_when_code_not_req(hass):
assert STATE_ALARM_DISARMED == \
hass.states.get(entity_id).state
common.async_alarm_arm_custom_bypass(hass, 0)
await hass.async_block_till_done()
await common.async_alarm_arm_custom_bypass(hass, 0)
assert STATE_ALARM_ARMED_CUSTOM_BYPASS == \
hass.states.get(entity_id).state