Skip to content

chore: give every coverage pragma a reason (TS6) - #32

Merged
lesnik512 merged 1 commit into
mainfrom
chore/pragma-reasons
Sep 27, 2026
Merged

lesnik512 merged 1 commit into
mainfrom
chore/pragma-reasons

Conversation

@lesnik512

Copy link
Copy Markdown
Member

Brings the coverage pragmas in line with TS5 and TS6: every # pragma: no cover now carries its reason on the same line. exclude_also was already exactly ["if typing.TYPE_CHECKING:"] and no file is excluded, so TS5 needed no change.

Counts: 0 tested / 0 deleted / 4 reasoned.

  • tests/test_inject.py: body of a method inject refuses to call without DIInterceptor.
  • tests/test_aio.py (2): the coveragepy #2124 workaround; the multi-line comment above the two lines moves onto the pragmas, which is now where the reason lives.
  • examples/app.py: the __main__ guard; tests call build_server() directly.

modern_di_grpc/main.py already had a reason (in parentheses) and is left untouched.

Local checks

  • just install: ok
  • just lint-ci: pass
  • just test-ci: 37 passed, 100 % coverage

@lesnik512
lesnik512 merged commit f0c1a6f into main Sep 27, 2026
12 checks passed
@lesnik512
lesnik512 deleted the chore/pragma-reasons branch September 27, 2026 16:34
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant