Speedup Reolink tests by using scope="module" (#125215)
* use scope="module" * Instead of side_effect = None, use reset_mock(side_efffect=True) * fix tests
This commit is contained in:
parent
a9d12608bd
commit
8ef7cae36d
13 changed files with 101 additions and 12 deletions
|
@ -74,6 +74,8 @@ async def test_floodlight_mode_select(
|
|||
|
||||
assert hass.states.get(entity_id).state == STATE_UNKNOWN
|
||||
|
||||
reolink_connect.set_whiteled.reset_mock(side_effect=True)
|
||||
|
||||
|
||||
async def test_play_quick_reply_message(
|
||||
hass: HomeAssistant,
|
||||
|
@ -99,6 +101,8 @@ async def test_play_quick_reply_message(
|
|||
)
|
||||
reolink_connect.play_quick_reply.assert_called_once()
|
||||
|
||||
reolink_connect.quick_reply_dict = MagicMock()
|
||||
|
||||
|
||||
async def test_chime_select(
|
||||
hass: HomeAssistant,
|
||||
|
@ -153,3 +157,5 @@ async def test_chime_select(
|
|||
await hass.async_block_till_done()
|
||||
|
||||
assert hass.states.get(entity_id).state == STATE_UNKNOWN
|
||||
|
||||
test_chime.set_tone.reset_mock(side_effect=True)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue