From 7e619fcb7ebd198ffa32b89d109c38db234816b0 Mon Sep 17 00:00:00 2001 From: Steven B <51370195+sdb9696@users.noreply.github.com> Date: Tue, 21 Jan 2025 14:02:59 +0000 Subject: [PATCH] Fix clean tests --- tests/smart/modules/test_clean.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/tests/smart/modules/test_clean.py b/tests/smart/modules/test_clean.py index beae0143..70cbcb15 100644 --- a/tests/smart/modules/test_clean.py +++ b/tests/smart/modules/test_clean.py @@ -117,6 +117,10 @@ async def test_actions( async def test_post_update_hook(dev: SmartDevice, err_status: list, error: ErrorCode): """Test that post update hook sets error states correctly.""" clean = next(get_parent_and_child_modules(dev, Module.Clean)) + assert clean + + # _post_update_hook will pop an item off the status list so create a copy. + err_status = [e for e in err_status] clean.data["getVacStatus"]["err_status"] = err_status await clean._post_update_hook()