ci: add strict-no-cover to detect unnecessary coverage pragmas (#1897)

This commit is contained in:
Max Isbey 2026-01-23 20:00:20 +00:00 • committed by GitHub
commit a7ddfdae07
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -391,8 +391,7 @@ async def test_create_message_tool_result_validation():
# Case 8: empty messages list - skips validation entirely
# Covers the `if messages:` branch (line 280->302)
# TODO(Marcelo): Drop the pragma once https://github.com/coveragepy/coveragepy/issues/1987 is fixed.
with anyio.move_on_after(0.01): # pragma: no cover
with anyio.move_on_after(0.01): # pragma: no branch
await session.create_message(messages=[], max_tokens=100)