diff --git a/tests/catalog/test_hive.py b/tests/catalog/test_hive.py index 88b653e44f..a8c0c943da 100644 --- a/tests/catalog/test_hive.py +++ b/tests/catalog/test_hive.py @@ -1314,8 +1314,8 @@ def test_hive_wait_for_lock() -> None: assert catalog._client.check_lock.call_count == 3 # lock wait should exit with WaitingForLockException finally after enough retries + catalog._client.check_lock.reset_mock() catalog._client.check_lock.side_effect = [waiting for _ in range(10)] - catalog._client.check_lock.call_count = 0 with pytest.raises(WaitingForLockException): catalog._wait_for_lock("db", "tbl", lockid, catalog._client) assert catalog._client.check_lock.call_count == 5